From e2584f4ecda4ad21d879ebe34db8298c91472a9f Mon Sep 17 00:00:00 2001 From: parteek65 Date: Wed, 17 Jul 2024 14:06:35 +0530 Subject: [PATCH] Added Recommendation Unit and Action Types --- .openapi-generator/FILES | 93 +- README.md | 44 +- docs/ActionType.md | 33 + docs/ActionTypeFilters.md | 31 + docs/ActionTypeFiltersServicesInner.md | 28 + docs/CreateActionTypeRequest.md | 32 + docs/CreateActionTypeResponse.md | 33 + docs/CreatePolicyTemplateRequest.md | 2 +- docs/CreatePolicyTemplateResponse.md | 2 +- docs/CreateRecommendationUnitRequest.md | 37 + docs/CreateRecommendationUnitResponse.md | 37 + docs/GetActionTypeRequest.md | 30 + docs/GetActionTypeResponse.md | 30 + docs/GetPolicyTemplateByIDResponse.md | 2 +- docs/GetRecommendationUnitByIdResponse.md | 2 +- docs/GetRecommendationUnitRequest.md | 30 + docs/GetRecommendationUnitsResponse.md | 3 +- ...GetTenantPoliciesWithSettingsAPIRequest.md | 1 + docs/GetTenantPoliciesWithSettingsRequest.md | 1 + docs/GetTenantPolicyByIdResponse.md | 2 +- docs/GetTenantUserProfileResponse.md | 51 + docs/PasswordChangeEmailRequest.md | 30 + docs/PasswordChangeEmailResponse.md | 29 + docs/PolicyTemplate.md | 2 +- docs/PolicyTemplateFilters.md | 2 +- docs/PolicyTemplateUpdateFieldsMixin.md | 2 +- docs/ProviderConfigInput.md | 1 + docs/ProviderConfigOutput.md | 1 + docs/QueryDetailsDerivedVariables.md | 31 + docs/RecommendationEngineServiceApi.md | 121 +- docs/RecommendationQueryDetails.md | 30 + docs/RecommendationUnit.md | 37 + docs/RecommendationUnitFilters.md | 34 + docs/RecommendationUnitServiceApi.md | 284 +++++ docs/ResponseGetTenantUserProfileResponse.md | 30 + docs/ResponsePasswordChangeEmailResponse.md | 30 + docs/Service.md | 29 + docs/StorageLensConfig.md | 30 + docs/TenantPolicy.md | 2 +- docs/TenantPolicyFilters.md | 2 +- docs/TenantUserServiceApi.md | 138 ++ docs/TenantUsersApi.md | 273 ++++ docs/TenantVerifyRequestWithUser.md | 1 + docs/UpdateActionTypeRequest.md | 33 + docs/UpdateActionTypeResponse.md | 33 + docs/UpdatePolicyTemplateRequest.md | 2 +- docs/UpdatePolicyTemplateResponse.md | 2 +- docs/UpdateRecommendationUnitRequest.md | 37 + docs/UpdateRecommendationUnitResponse.md | 37 + onelens_backend_client/__init__.py | 30 +- onelens_backend_client/api/__init__.py | 1 + .../api/recommendation_engine_service_api.py | 404 +++++- .../api/recommendation_unit_service_api.py | 1123 +++++++++++++++++ .../api/tenant_user_service_api.py | 542 ++++++++ .../api/tenant_users_api.py | 1033 +++++++++++++++ onelens_backend_client/models/__init__.py | 29 +- onelens_backend_client/models/action_type.py | 104 ++ .../models/action_type_filters.py | 104 ++ .../action_type_filters_services_inner.py | 134 ++ .../models/create_action_type_request.py | 102 ++ .../models/create_action_type_response.py | 104 ++ .../models/create_policy_template_request.py | 6 +- .../models/create_policy_template_response.py | 6 +- .../create_recommendation_unit_request.py | 123 ++ .../create_recommendation_unit_response.py | 123 ++ .../models/get_action_type_request.py | 97 ++ .../models/get_action_type_response.py | 101 ++ .../get_policy_template_by_id_response.py | 6 +- .../get_recommendation_unit_by_id_response.py | 6 +- .../models/get_recommendation_unit_request.py | 97 ++ .../get_recommendation_units_response.py | 14 +- ...nant_policies_with_settings_api_request.py | 15 +- ...t_tenant_policies_with_settings_request.py | 13 +- .../get_tenant_policy_by_id_response.py | 6 +- .../get_tenant_user_profile_response.py | 231 ++++ .../models/password_change_email_request.py | 89 ++ .../models/password_change_email_response.py | 87 ++ .../models/policy_template.py | 6 +- .../models/policy_template_filters.py | 6 +- .../policy_template_update_fields_mixin.py | 6 +- .../models/provider_config_input.py | 15 +- .../models/provider_config_output.py | 15 +- .../models/query_details_derived_variables.py | 91 ++ .../models/recommendation_query_details.py | 97 ++ .../models/recommendation_unit.py | 123 ++ .../models/recommendation_unit_filters.py | 103 ++ ...sponse_get_tenant_user_profile_response.py | 98 ++ ...response_password_change_email_response.py | 98 ++ onelens_backend_client/models/service.py | 134 ++ .../models/storage_lens_config.py | 99 ++ .../models/tenant_policy.py | 6 +- .../models/tenant_policy_filters.py | 6 +- .../models/tenant_provider_attributes.py | 1 + .../models/tenant_verify_request_with_user.py | 15 +- .../models/update_action_type_request.py | 104 ++ .../models/update_action_type_response.py | 104 ++ .../models/update_policy_template_request.py | 6 +- .../models/update_policy_template_response.py | 6 +- .../update_recommendation_unit_request.py | 123 ++ .../update_recommendation_unit_response.py | 123 ++ test/test_action_type.py | 59 + test/test_action_type_filters.py | 57 + ...test_action_type_filters_services_inner.py | 50 + test/test_create_action_type_request.py | 57 + test/test_create_action_type_response.py | 59 + ...test_create_recommendation_unit_request.py | 80 ++ ...est_create_recommendation_unit_response.py | 80 ++ test/test_get_action_type_request.py | 61 + test/test_get_action_type_response.py | 76 ++ test/test_get_recommendation_unit_request.py | 70 + test/test_get_tenant_user_profile_response.py | 76 ++ test/test_password_change_email_request.py | 54 + test/test_password_change_email_response.py | 52 + test/test_query_details_derived_variables.py | 56 + test/test_recommendation_query_details.py | 64 + test/test_recommendation_unit.py | 80 ++ test/test_recommendation_unit_filters.py | 66 + test/test_recommendation_unit_service_api.py | 59 + ...sponse_get_tenant_user_profile_response.py | 57 + ...response_password_change_email_response.py | 55 + test/test_service.py | 50 + test/test_storage_lens_config.py | 52 + test/test_update_action_type_request.py | 59 + test/test_update_action_type_response.py | 59 + ...test_update_recommendation_unit_request.py | 80 ++ ...est_update_recommendation_unit_response.py | 80 ++ 126 files changed, 9387 insertions(+), 183 deletions(-) create mode 100644 docs/ActionType.md create mode 100644 docs/ActionTypeFilters.md create mode 100644 docs/ActionTypeFiltersServicesInner.md create mode 100644 docs/CreateActionTypeRequest.md create mode 100644 docs/CreateActionTypeResponse.md create mode 100644 docs/CreateRecommendationUnitRequest.md create mode 100644 docs/CreateRecommendationUnitResponse.md create mode 100644 docs/GetActionTypeRequest.md create mode 100644 docs/GetActionTypeResponse.md create mode 100644 docs/GetRecommendationUnitRequest.md create mode 100644 docs/GetTenantUserProfileResponse.md create mode 100644 docs/PasswordChangeEmailRequest.md create mode 100644 docs/PasswordChangeEmailResponse.md create mode 100644 docs/QueryDetailsDerivedVariables.md create mode 100644 docs/RecommendationQueryDetails.md create mode 100644 docs/RecommendationUnit.md create mode 100644 docs/RecommendationUnitFilters.md create mode 100644 docs/RecommendationUnitServiceApi.md create mode 100644 docs/ResponseGetTenantUserProfileResponse.md create mode 100644 docs/ResponsePasswordChangeEmailResponse.md create mode 100644 docs/Service.md create mode 100644 docs/StorageLensConfig.md create mode 100644 docs/UpdateActionTypeRequest.md create mode 100644 docs/UpdateActionTypeResponse.md create mode 100644 docs/UpdateRecommendationUnitRequest.md create mode 100644 docs/UpdateRecommendationUnitResponse.md create mode 100644 onelens_backend_client/api/recommendation_unit_service_api.py create mode 100644 onelens_backend_client/models/action_type.py create mode 100644 onelens_backend_client/models/action_type_filters.py create mode 100644 onelens_backend_client/models/action_type_filters_services_inner.py create mode 100644 onelens_backend_client/models/create_action_type_request.py create mode 100644 onelens_backend_client/models/create_action_type_response.py create mode 100644 onelens_backend_client/models/create_recommendation_unit_request.py create mode 100644 onelens_backend_client/models/create_recommendation_unit_response.py create mode 100644 onelens_backend_client/models/get_action_type_request.py create mode 100644 onelens_backend_client/models/get_action_type_response.py create mode 100644 onelens_backend_client/models/get_recommendation_unit_request.py create mode 100644 onelens_backend_client/models/get_tenant_user_profile_response.py create mode 100644 onelens_backend_client/models/password_change_email_request.py create mode 100644 onelens_backend_client/models/password_change_email_response.py create mode 100644 onelens_backend_client/models/query_details_derived_variables.py create mode 100644 onelens_backend_client/models/recommendation_query_details.py create mode 100644 onelens_backend_client/models/recommendation_unit.py create mode 100644 onelens_backend_client/models/recommendation_unit_filters.py create mode 100644 onelens_backend_client/models/response_get_tenant_user_profile_response.py create mode 100644 onelens_backend_client/models/response_password_change_email_response.py create mode 100644 onelens_backend_client/models/service.py create mode 100644 onelens_backend_client/models/storage_lens_config.py create mode 100644 onelens_backend_client/models/update_action_type_request.py create mode 100644 onelens_backend_client/models/update_action_type_response.py create mode 100644 onelens_backend_client/models/update_recommendation_unit_request.py create mode 100644 onelens_backend_client/models/update_recommendation_unit_response.py create mode 100644 test/test_action_type.py create mode 100644 test/test_action_type_filters.py create mode 100644 test/test_action_type_filters_services_inner.py create mode 100644 test/test_create_action_type_request.py create mode 100644 test/test_create_action_type_response.py create mode 100644 test/test_create_recommendation_unit_request.py create mode 100644 test/test_create_recommendation_unit_response.py create mode 100644 test/test_get_action_type_request.py create mode 100644 test/test_get_action_type_response.py create mode 100644 test/test_get_recommendation_unit_request.py create mode 100644 test/test_get_tenant_user_profile_response.py create mode 100644 test/test_password_change_email_request.py create mode 100644 test/test_password_change_email_response.py create mode 100644 test/test_query_details_derived_variables.py create mode 100644 test/test_recommendation_query_details.py create mode 100644 test/test_recommendation_unit.py create mode 100644 test/test_recommendation_unit_filters.py create mode 100644 test/test_recommendation_unit_service_api.py create mode 100644 test/test_response_get_tenant_user_profile_response.py create mode 100644 test/test_response_password_change_email_response.py create mode 100644 test/test_service.py create mode 100644 test/test_storage_lens_config.py create mode 100644 test/test_update_action_type_request.py create mode 100644 test/test_update_action_type_response.py create mode 100644 test/test_update_recommendation_unit_request.py create mode 100644 test/test_update_recommendation_unit_response.py diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index fc106f68..a0134e4e 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -3,6 +3,9 @@ .gitlab-ci.yml .travis.yml README.md +docs/ActionType.md +docs/ActionTypeFilters.md +docs/ActionTypeFiltersServicesInner.md docs/ActivatePolicyTemplateRequest.md docs/AddTenantPolicyExclusionsAPIRequest.md docs/AddTenantPolicyExclusionsRequest.md @@ -27,6 +30,8 @@ docs/City.md docs/CloudMetadataApi.md docs/CloudMetadataServiceApi.md docs/Country.md +docs/CreateActionTypeRequest.md +docs/CreateActionTypeResponse.md docs/CreateAuth0AndOnelensUserResponse.md docs/CreateAuth0UserRequest.md docs/CreateDefaultHierarchyRequest.md @@ -41,8 +46,9 @@ docs/CreateOrganizationResponse.md docs/CreatePolicyTemplatePackRequest.md docs/CreatePolicyTemplatePackResponse.md docs/CreatePolicyTemplateRequest.md -docs/CreatePolicyTemplateRequestServicesInner.md docs/CreatePolicyTemplateResponse.md +docs/CreateRecommendationUnitRequest.md +docs/CreateRecommendationUnitResponse.md docs/CreateTenantProviderRequest.md docs/CreateTenantProviderResponse.md docs/CreateTenantRequestWithUser.md @@ -69,7 +75,6 @@ docs/DeactivatePolicyTemplateRequest.md docs/DefaultApi.md docs/DeleteHierarchyNodeRequest.md docs/DeprecatePolicyTemplateRequest.md -docs/DerivedVariable.md docs/Details.md docs/Details1.md docs/Details2.md @@ -95,6 +100,8 @@ docs/EndRange.md docs/Features.md docs/FirstName.md docs/GcpService.md +docs/GetActionTypeRequest.md +docs/GetActionTypeResponse.md docs/GetAllPolicyViolationsAPIRequest.md docs/GetAllPolicyViolationsRequest.md docs/GetAllPolicyViolationsResponse.md @@ -139,6 +146,7 @@ docs/GetRecommendationTicketRequest.md docs/GetRecommendationTicketResponse.md docs/GetRecommendationUnitByIdRequest.md docs/GetRecommendationUnitByIdResponse.md +docs/GetRecommendationUnitRequest.md docs/GetRecommendationUnitsRequest.md docs/GetRecommendationUnitsResponse.md docs/GetResourceHierarchyMappingByOlIdRequest.md @@ -174,6 +182,7 @@ docs/GetTenantTicketsRequest.md docs/GetTenantTicketsResponse.md docs/GetTenantUserByIDRequest.md docs/GetTenantUserByIDResponse.md +docs/GetTenantUserProfileResponse.md docs/GetTenantUsersWithFilterAPIRequest.md docs/GetTenantUsersWithFilterRequest.md docs/GetTenantUsersWithFilterResponse.md @@ -231,6 +240,8 @@ docs/OverrideTenantPolicyExclusionsRequest.md docs/OverrideTenantPolicyExclusionsResponse.md docs/PaginationFields.md docs/PaginationParams.md +docs/PasswordChangeEmailRequest.md +docs/PasswordChangeEmailResponse.md docs/PoliciesPolicyTemplatePacksApi.md docs/PoliciesPolicyTemplatesApi.md docs/PolicyCategory.md @@ -259,7 +270,7 @@ docs/Provider.md docs/ProviderConfigInput.md docs/ProviderConfigOutput.md docs/PublishCustomHierarchyRequest.md -docs/QueryDetails.md +docs/QueryDetailsDerivedVariables.md docs/QueryFilters.md docs/QueryOrder.md docs/RecommendationApi.md @@ -270,12 +281,16 @@ docs/RecommendationEngineRequest.md docs/RecommendationEngineResponse.md docs/RecommendationEngineServiceApi.md docs/RecommendationParams.md +docs/RecommendationQueryDetails.md docs/RecommendationServiceApi.md docs/RecommendationTicket.md docs/RecommendationTicketAPIRequestInput.md docs/RecommendationTicketAPIRequestOutput.md docs/RecommendationTicketRequest.md docs/RecommendationTicketResponse.md +docs/RecommendationUnit.md +docs/RecommendationUnitFilters.md +docs/RecommendationUnitServiceApi.md docs/RelationshipConfigItem.md docs/ResourceCatalog.md docs/ResourceCatalogApi.md @@ -329,11 +344,13 @@ docs/ResponseGetTenantProviderByIDResponse.md docs/ResponseGetTenantProvidersResponse.md docs/ResponseGetTenantTicketsResponse.md docs/ResponseGetTenantUserByIDResponse.md +docs/ResponseGetTenantUserProfileResponse.md docs/ResponseGetTenantUsersWithFilterResponse.md docs/ResponseGetTenantsResponse.md docs/ResponseGetTicketByIdPolicyDetailsResponse.md docs/ResponseOverrideTenantAnomalyConfigResponse.md docs/ResponseOverrideTenantPolicyExclusionsResponse.md +docs/ResponsePasswordChangeEmailResponse.md docs/ResponseRecommendationEngineResponse.md docs/ResponseRecommendationTicketResponse.md docs/ResponseResourceCatalogResponse.md @@ -348,13 +365,13 @@ docs/ResponseUpdateTenantTicketsResponse.md docs/ResponseUpdateTenantUserDetailsResponse.md docs/ResponseUpdateTenantUserResponse.md docs/RuleType.md +docs/Service.md docs/ServiceCatalog.md docs/ServiceCatalogApi.md docs/ServiceCatalogRequest.md docs/ServiceCatalogRequestFind.md docs/ServiceCatalogResponse.md docs/ServiceCatalogServiceApi.md -docs/ServiceConfig.md docs/SetTenantStatusRequest.md docs/SortCriteria.md docs/Sources.md @@ -362,6 +379,7 @@ docs/State.md docs/Status.md docs/Status1.md docs/Statuses.md +docs/StorageLensConfig.md docs/Tenant.md docs/TenantAnomaliesApi.md docs/TenantAnomalyServiceApi.md @@ -416,6 +434,8 @@ docs/TicketState.md docs/TimeDimensionOutput.md docs/TimeDimensionOutputCompareDateRangeInner.md docs/Timezone.md +docs/UpdateActionTypeRequest.md +docs/UpdateActionTypeResponse.md docs/UpdateHierarchyNodeAPIRequest.md docs/UpdateHierarchyNodeRequest.md docs/UpdateHierarchyNodeResponse.md @@ -423,6 +443,8 @@ docs/UpdateOrganizationRequest.md docs/UpdateOrganizationResponse.md docs/UpdatePolicyTemplateRequest.md docs/UpdatePolicyTemplateResponse.md +docs/UpdateRecommendationUnitRequest.md +docs/UpdateRecommendationUnitResponse.md docs/UpdateTenantPolicySettingLastRunAtRequest.md docs/UpdateTenantRequest.md docs/UpdateTenantResponse.md @@ -468,6 +490,7 @@ onelens_backend_client/api/recommendation_api.py onelens_backend_client/api/recommendation_engine_api.py onelens_backend_client/api/recommendation_engine_service_api.py onelens_backend_client/api/recommendation_service_api.py +onelens_backend_client/api/recommendation_unit_service_api.py onelens_backend_client/api/resource_catalog_api.py onelens_backend_client/api/resource_catalog_service_api.py onelens_backend_client/api/resource_mapping_service_api.py @@ -496,6 +519,9 @@ onelens_backend_client/api_response.py onelens_backend_client/configuration.py onelens_backend_client/exceptions.py onelens_backend_client/models/__init__.py +onelens_backend_client/models/action_type.py +onelens_backend_client/models/action_type_filters.py +onelens_backend_client/models/action_type_filters_services_inner.py onelens_backend_client/models/activate_policy_template_request.py onelens_backend_client/models/add_tenant_policy_exclusions_api_request.py onelens_backend_client/models/add_tenant_policy_exclusions_request.py @@ -517,6 +543,8 @@ onelens_backend_client/models/bulk_update_tenant_tickets_request_mixin.py onelens_backend_client/models/bulk_update_tenant_tickets_response.py onelens_backend_client/models/city.py onelens_backend_client/models/country.py +onelens_backend_client/models/create_action_type_request.py +onelens_backend_client/models/create_action_type_response.py onelens_backend_client/models/create_auth0_and_onelens_user_response.py onelens_backend_client/models/create_auth0_user_request.py onelens_backend_client/models/create_default_hierarchy_request.py @@ -531,8 +559,9 @@ onelens_backend_client/models/create_organization_response.py onelens_backend_client/models/create_policy_template_pack_request.py onelens_backend_client/models/create_policy_template_pack_response.py onelens_backend_client/models/create_policy_template_request.py -onelens_backend_client/models/create_policy_template_request_services_inner.py onelens_backend_client/models/create_policy_template_response.py +onelens_backend_client/models/create_recommendation_unit_request.py +onelens_backend_client/models/create_recommendation_unit_response.py onelens_backend_client/models/create_tenant_provider_request.py onelens_backend_client/models/create_tenant_provider_response.py onelens_backend_client/models/create_tenant_request_with_user.py @@ -557,7 +586,6 @@ onelens_backend_client/models/data_retriever_response.py onelens_backend_client/models/deactivate_policy_template_request.py onelens_backend_client/models/delete_hierarchy_node_request.py onelens_backend_client/models/deprecate_policy_template_request.py -onelens_backend_client/models/derived_variable.py onelens_backend_client/models/details.py onelens_backend_client/models/details1.py onelens_backend_client/models/details2.py @@ -583,6 +611,8 @@ onelens_backend_client/models/end_range.py onelens_backend_client/models/features.py onelens_backend_client/models/first_name.py onelens_backend_client/models/gcp_service.py +onelens_backend_client/models/get_action_type_request.py +onelens_backend_client/models/get_action_type_response.py onelens_backend_client/models/get_all_policy_violations_api_request.py onelens_backend_client/models/get_all_policy_violations_request.py onelens_backend_client/models/get_all_policy_violations_response.py @@ -627,6 +657,7 @@ onelens_backend_client/models/get_recommendation_ticket_request.py onelens_backend_client/models/get_recommendation_ticket_response.py onelens_backend_client/models/get_recommendation_unit_by_id_request.py onelens_backend_client/models/get_recommendation_unit_by_id_response.py +onelens_backend_client/models/get_recommendation_unit_request.py onelens_backend_client/models/get_recommendation_units_request.py onelens_backend_client/models/get_recommendation_units_response.py onelens_backend_client/models/get_resource_hierarchy_mapping_by_ol_id_request.py @@ -662,6 +693,7 @@ onelens_backend_client/models/get_tenant_tickets_request.py onelens_backend_client/models/get_tenant_tickets_response.py onelens_backend_client/models/get_tenant_user_by_id_request.py onelens_backend_client/models/get_tenant_user_by_id_response.py +onelens_backend_client/models/get_tenant_user_profile_response.py onelens_backend_client/models/get_tenant_users_with_filter_api_request.py onelens_backend_client/models/get_tenant_users_with_filter_request.py onelens_backend_client/models/get_tenant_users_with_filter_response.py @@ -716,6 +748,8 @@ onelens_backend_client/models/override_tenant_policy_exclusions_request.py onelens_backend_client/models/override_tenant_policy_exclusions_response.py onelens_backend_client/models/pagination_fields.py onelens_backend_client/models/pagination_params.py +onelens_backend_client/models/password_change_email_request.py +onelens_backend_client/models/password_change_email_response.py onelens_backend_client/models/policy_category.py onelens_backend_client/models/policy_execution_type.py onelens_backend_client/models/policy_recommendation_params.py @@ -740,7 +774,7 @@ onelens_backend_client/models/provider.py onelens_backend_client/models/provider_config_input.py onelens_backend_client/models/provider_config_output.py onelens_backend_client/models/publish_custom_hierarchy_request.py -onelens_backend_client/models/query_details.py +onelens_backend_client/models/query_details_derived_variables.py onelens_backend_client/models/query_filters.py onelens_backend_client/models/query_order.py onelens_backend_client/models/recommendation_engine.py @@ -748,11 +782,14 @@ onelens_backend_client/models/recommendation_engine_api_request.py onelens_backend_client/models/recommendation_engine_request.py onelens_backend_client/models/recommendation_engine_response.py onelens_backend_client/models/recommendation_params.py +onelens_backend_client/models/recommendation_query_details.py onelens_backend_client/models/recommendation_ticket.py onelens_backend_client/models/recommendation_ticket_api_request_input.py onelens_backend_client/models/recommendation_ticket_api_request_output.py onelens_backend_client/models/recommendation_ticket_request.py onelens_backend_client/models/recommendation_ticket_response.py +onelens_backend_client/models/recommendation_unit.py +onelens_backend_client/models/recommendation_unit_filters.py onelens_backend_client/models/relationship_config_item.py onelens_backend_client/models/resource_catalog.py onelens_backend_client/models/resource_catalog_request.py @@ -803,11 +840,13 @@ onelens_backend_client/models/response_get_tenant_provider_by_id_response.py onelens_backend_client/models/response_get_tenant_providers_response.py onelens_backend_client/models/response_get_tenant_tickets_response.py onelens_backend_client/models/response_get_tenant_user_by_id_response.py +onelens_backend_client/models/response_get_tenant_user_profile_response.py onelens_backend_client/models/response_get_tenant_users_with_filter_response.py onelens_backend_client/models/response_get_tenants_response.py onelens_backend_client/models/response_get_ticket_by_id_policy_details_response.py onelens_backend_client/models/response_override_tenant_anomaly_config_response.py onelens_backend_client/models/response_override_tenant_policy_exclusions_response.py +onelens_backend_client/models/response_password_change_email_response.py onelens_backend_client/models/response_recommendation_engine_response.py onelens_backend_client/models/response_recommendation_ticket_response.py onelens_backend_client/models/response_resource_catalog_response.py @@ -822,11 +861,11 @@ onelens_backend_client/models/response_update_tenant_tickets_response.py onelens_backend_client/models/response_update_tenant_user_details_response.py onelens_backend_client/models/response_update_tenant_user_response.py onelens_backend_client/models/rule_type.py +onelens_backend_client/models/service.py onelens_backend_client/models/service_catalog.py onelens_backend_client/models/service_catalog_request.py onelens_backend_client/models/service_catalog_request_find.py onelens_backend_client/models/service_catalog_response.py -onelens_backend_client/models/service_config.py onelens_backend_client/models/set_tenant_status_request.py onelens_backend_client/models/sort_criteria.py onelens_backend_client/models/sources.py @@ -834,6 +873,7 @@ onelens_backend_client/models/state.py onelens_backend_client/models/status.py onelens_backend_client/models/status1.py onelens_backend_client/models/statuses.py +onelens_backend_client/models/storage_lens_config.py onelens_backend_client/models/tenant.py onelens_backend_client/models/tenant_anomaly_setting_filters.py onelens_backend_client/models/tenant_anomaly_settings.py @@ -872,6 +912,8 @@ onelens_backend_client/models/ticket_state.py onelens_backend_client/models/time_dimension_output.py onelens_backend_client/models/time_dimension_output_compare_date_range_inner.py onelens_backend_client/models/timezone.py +onelens_backend_client/models/update_action_type_request.py +onelens_backend_client/models/update_action_type_response.py onelens_backend_client/models/update_hierarchy_node_api_request.py onelens_backend_client/models/update_hierarchy_node_request.py onelens_backend_client/models/update_hierarchy_node_response.py @@ -879,6 +921,8 @@ onelens_backend_client/models/update_organization_request.py onelens_backend_client/models/update_organization_response.py onelens_backend_client/models/update_policy_template_request.py onelens_backend_client/models/update_policy_template_response.py +onelens_backend_client/models/update_recommendation_unit_request.py +onelens_backend_client/models/update_recommendation_unit_response.py onelens_backend_client/models/update_tenant_policy_setting_last_run_at_request.py onelens_backend_client/models/update_tenant_request.py onelens_backend_client/models/update_tenant_response.py @@ -911,11 +955,30 @@ setup.cfg setup.py test-requirements.txt test/__init__.py -test/test_auth0_user_all_fields.py -test/test_create_auth0_and_onelens_user_response.py -test/test_create_tenant_user_request_persona.py -test/test_get_all_tenant_users_item.py -test/test_response_create_auth0_and_onelens_user_response.py -test/test_sources.py -test/test_tenant_policy_system_state.py +test/test_action_type.py +test/test_action_type_filters.py +test/test_action_type_filters_services_inner.py +test/test_create_action_type_request.py +test/test_create_action_type_response.py +test/test_create_recommendation_unit_request.py +test/test_create_recommendation_unit_response.py +test/test_get_action_type_request.py +test/test_get_action_type_response.py +test/test_get_recommendation_unit_request.py +test/test_get_tenant_user_profile_response.py +test/test_password_change_email_request.py +test/test_password_change_email_response.py +test/test_query_details_derived_variables.py +test/test_recommendation_query_details.py +test/test_recommendation_unit.py +test/test_recommendation_unit_filters.py +test/test_recommendation_unit_service_api.py +test/test_response_get_tenant_user_profile_response.py +test/test_response_password_change_email_response.py +test/test_service.py +test/test_storage_lens_config.py +test/test_update_action_type_request.py +test/test_update_action_type_response.py +test/test_update_recommendation_unit_request.py +test/test_update_recommendation_unit_response.py tox.ini diff --git a/README.md b/README.md index 2b1f5eb0..03080079 100644 --- a/README.md +++ b/README.md @@ -135,11 +135,16 @@ Class | Method | Description *PolicyTemplateServiceApi* | [**get_policy_template_by_id**](docs/PolicyTemplateServiceApi.md#get_policy_template_by_id) | Retrieves a policy template by its unique identifier. *PolicyTemplateServiceApi* | [**get_policy_templates**](docs/PolicyTemplateServiceApi.md#get_policy_templates) | Retrieves all policy templates, optionally filtered by the parameters in the request. *PolicyTemplateServiceApi* | [**update_policy_template**](docs/PolicyTemplateServiceApi.md#update_policy_template) | Updates an existing policy template. -*RecommendationEngineServiceApi* | [**get_recommendation_unit_by_id**](docs/RecommendationEngineServiceApi.md#get_recommendation_unit_by_id) | Retrieves all Tenants with filters. -*RecommendationEngineServiceApi* | [**get_recommendation_units**](docs/RecommendationEngineServiceApi.md#get_recommendation_units) | Retrieves all recommendation units by filter +*RecommendationEngineServiceApi* | [**create_action_type**](docs/RecommendationEngineServiceApi.md#create_action_type) | Create Action Type +*RecommendationEngineServiceApi* | [**get_action_types**](docs/RecommendationEngineServiceApi.md#get_action_types) | Get Action Types *RecommendationEngineServiceApi* | [**get_recommendations**](docs/RecommendationEngineServiceApi.md#get_recommendations) | Get recommendations. +*RecommendationEngineServiceApi* | [**update_action_type**](docs/RecommendationEngineServiceApi.md#update_action_type) | Update Action Type *RecommendationServiceApi* | [**bulk_create**](docs/RecommendationServiceApi.md#bulk_create) | Creates bulk recommendations. *RecommendationServiceApi* | [**get_recommendation_by_ticket_id**](docs/RecommendationServiceApi.md#get_recommendation_by_ticket_id) | Get recommendations by ticket id. +*RecommendationUnitServiceApi* | [**create_recommendation_unit**](docs/RecommendationUnitServiceApi.md#create_recommendation_unit) | Create recommendation unit +*RecommendationUnitServiceApi* | [**get_recommendation_unit_by_id**](docs/RecommendationUnitServiceApi.md#get_recommendation_unit_by_id) | Retrieves Recommendation unit ID. +*RecommendationUnitServiceApi* | [**get_recommendation_units**](docs/RecommendationUnitServiceApi.md#get_recommendation_units) | Retrieves all recommendation units with filters +*RecommendationUnitServiceApi* | [**update_recommendation_unit**](docs/RecommendationUnitServiceApi.md#update_recommendation_unit) | Update recommendation unit *ResourceCatalogApi* | [**get_resource_catalog**](docs/ResourceCatalogApi.md#get_resource_catalog) | Get Resource Catalog *ResourceCatalogApi* | [**get_resource_catalog_0**](docs/ResourceCatalogApi.md#get_resource_catalog_0) | Get Resource Catalog *ResourceCatalogApi* | [**get_resource_catalog_with_relationships**](docs/ResourceCatalogApi.md#get_resource_catalog_with_relationships) | Get Resource Catalog With Relationships @@ -239,8 +244,10 @@ Class | Method | Description *TenantUserServiceApi* | [**create_tenant_user_from_ol_user_id**](docs/TenantUserServiceApi.md#create_tenant_user_from_ol_user_id) | Creates a new user from onelens user id (ol_user_id). *TenantUserServiceApi* | [**disable_tenant_user**](docs/TenantUserServiceApi.md#disable_tenant_user) | Disables an existing tenant user. *TenantUserServiceApi* | [**enable_tenant_user**](docs/TenantUserServiceApi.md#enable_tenant_user) | Enables an existing tenant user. +*TenantUserServiceApi* | [**enable_tenant_user_with_system**](docs/TenantUserServiceApi.md#enable_tenant_user_with_system) | System Enables an existing tenant user. *TenantUserServiceApi* | [**get_tenant_user_by_ol_user_id**](docs/TenantUserServiceApi.md#get_tenant_user_by_ol_user_id) | Retrieves a tenant user by its unique onelens user id (ol_user_id). *TenantUserServiceApi* | [**get_tenant_users**](docs/TenantUserServiceApi.md#get_tenant_users) | Retrieves all tenant users. +*TenantUserServiceApi* | [**send_email_to_user_for_password_change**](docs/TenantUserServiceApi.md#send_email_to_user_for_password_change) | Sends a password change email to the user. *TenantUserServiceApi* | [**update_tenant_user**](docs/TenantUserServiceApi.md#update_tenant_user) | Updates an existing tenant user. *TenantUserServiceApi* | [**update_tenant_user_details**](docs/TenantUserServiceApi.md#update_tenant_user_details) | Updates tenant user details. *TenantUsersApi* | [**create_tenant_user**](docs/TenantUsersApi.md#create_tenant_user) | Create a new user in the Tenant Database. @@ -253,6 +260,10 @@ Class | Method | Description *TenantUsersApi* | [**get_all_tenant_users_with_filter_0**](docs/TenantUsersApi.md#get_all_tenant_users_with_filter_0) | Get All Tenant Users With Filter *TenantUsersApi* | [**get_tenant_user_by_ol_user_id**](docs/TenantUsersApi.md#get_tenant_user_by_ol_user_id) | Get a user from the Tenant Database. *TenantUsersApi* | [**get_tenant_user_by_ol_user_id_0**](docs/TenantUsersApi.md#get_tenant_user_by_ol_user_id_0) | Get Tenant User By Ol User Id +*TenantUsersApi* | [**get_tenant_user_profile**](docs/TenantUsersApi.md#get_tenant_user_profile) | Get user profile from the Tenant Database. +*TenantUsersApi* | [**get_tenant_user_profile_0**](docs/TenantUsersApi.md#get_tenant_user_profile_0) | Get Tenant User Profile +*TenantUsersApi* | [**send_email_to_user_for_password_change**](docs/TenantUsersApi.md#send_email_to_user_for_password_change) | Send user password change email. +*TenantUsersApi* | [**send_email_to_user_for_password_change_0**](docs/TenantUsersApi.md#send_email_to_user_for_password_change_0) | Send Email To User For Password Change *TenantUsersApi* | [**update_tenant_user**](docs/TenantUsersApi.md#update_tenant_user) | Update a user in the Tenant Database. *TenantUsersApi* | [**update_tenant_user_0**](docs/TenantUsersApi.md#update_tenant_user_0) | Update Tenant User *TenantUsersApi* | [**update_tenant_user_details**](docs/TenantUsersApi.md#update_tenant_user_details) | Update a user details in the Tenant Database. @@ -308,6 +319,9 @@ Class | Method | Description ## Documentation For Models + - [ActionType](docs/ActionType.md) + - [ActionTypeFilters](docs/ActionTypeFilters.md) + - [ActionTypeFiltersServicesInner](docs/ActionTypeFiltersServicesInner.md) - [ActivatePolicyTemplateRequest](docs/ActivatePolicyTemplateRequest.md) - [AddTenantPolicyExclusionsAPIRequest](docs/AddTenantPolicyExclusionsAPIRequest.md) - [AddTenantPolicyExclusionsRequest](docs/AddTenantPolicyExclusionsRequest.md) @@ -329,6 +343,8 @@ Class | Method | Description - [BulkUpdateTenantTicketsResponse](docs/BulkUpdateTenantTicketsResponse.md) - [City](docs/City.md) - [Country](docs/Country.md) + - [CreateActionTypeRequest](docs/CreateActionTypeRequest.md) + - [CreateActionTypeResponse](docs/CreateActionTypeResponse.md) - [CreateAuth0AndOnelensUserResponse](docs/CreateAuth0AndOnelensUserResponse.md) - [CreateAuth0UserRequest](docs/CreateAuth0UserRequest.md) - [CreateDefaultHierarchyRequest](docs/CreateDefaultHierarchyRequest.md) @@ -343,8 +359,9 @@ Class | Method | Description - [CreatePolicyTemplatePackRequest](docs/CreatePolicyTemplatePackRequest.md) - [CreatePolicyTemplatePackResponse](docs/CreatePolicyTemplatePackResponse.md) - [CreatePolicyTemplateRequest](docs/CreatePolicyTemplateRequest.md) - - [CreatePolicyTemplateRequestServicesInner](docs/CreatePolicyTemplateRequestServicesInner.md) - [CreatePolicyTemplateResponse](docs/CreatePolicyTemplateResponse.md) + - [CreateRecommendationUnitRequest](docs/CreateRecommendationUnitRequest.md) + - [CreateRecommendationUnitResponse](docs/CreateRecommendationUnitResponse.md) - [CreateTenantProviderRequest](docs/CreateTenantProviderRequest.md) - [CreateTenantProviderResponse](docs/CreateTenantProviderResponse.md) - [CreateTenantRequestWithUser](docs/CreateTenantRequestWithUser.md) @@ -369,7 +386,6 @@ Class | Method | Description - [DeactivatePolicyTemplateRequest](docs/DeactivatePolicyTemplateRequest.md) - [DeleteHierarchyNodeRequest](docs/DeleteHierarchyNodeRequest.md) - [DeprecatePolicyTemplateRequest](docs/DeprecatePolicyTemplateRequest.md) - - [DerivedVariable](docs/DerivedVariable.md) - [Details](docs/Details.md) - [Details1](docs/Details1.md) - [Details2](docs/Details2.md) @@ -395,6 +411,8 @@ Class | Method | Description - [Features](docs/Features.md) - [FirstName](docs/FirstName.md) - [GcpService](docs/GcpService.md) + - [GetActionTypeRequest](docs/GetActionTypeRequest.md) + - [GetActionTypeResponse](docs/GetActionTypeResponse.md) - [GetAllPolicyViolationsAPIRequest](docs/GetAllPolicyViolationsAPIRequest.md) - [GetAllPolicyViolationsRequest](docs/GetAllPolicyViolationsRequest.md) - [GetAllPolicyViolationsResponse](docs/GetAllPolicyViolationsResponse.md) @@ -439,6 +457,7 @@ Class | Method | Description - [GetRecommendationTicketResponse](docs/GetRecommendationTicketResponse.md) - [GetRecommendationUnitByIdRequest](docs/GetRecommendationUnitByIdRequest.md) - [GetRecommendationUnitByIdResponse](docs/GetRecommendationUnitByIdResponse.md) + - [GetRecommendationUnitRequest](docs/GetRecommendationUnitRequest.md) - [GetRecommendationUnitsRequest](docs/GetRecommendationUnitsRequest.md) - [GetRecommendationUnitsResponse](docs/GetRecommendationUnitsResponse.md) - [GetResourceHierarchyMappingByOlIdRequest](docs/GetResourceHierarchyMappingByOlIdRequest.md) @@ -474,6 +493,7 @@ Class | Method | Description - [GetTenantTicketsResponse](docs/GetTenantTicketsResponse.md) - [GetTenantUserByIDRequest](docs/GetTenantUserByIDRequest.md) - [GetTenantUserByIDResponse](docs/GetTenantUserByIDResponse.md) + - [GetTenantUserProfileResponse](docs/GetTenantUserProfileResponse.md) - [GetTenantUsersWithFilterAPIRequest](docs/GetTenantUsersWithFilterAPIRequest.md) - [GetTenantUsersWithFilterRequest](docs/GetTenantUsersWithFilterRequest.md) - [GetTenantUsersWithFilterResponse](docs/GetTenantUsersWithFilterResponse.md) @@ -528,6 +548,8 @@ Class | Method | Description - [OverrideTenantPolicyExclusionsResponse](docs/OverrideTenantPolicyExclusionsResponse.md) - [PaginationFields](docs/PaginationFields.md) - [PaginationParams](docs/PaginationParams.md) + - [PasswordChangeEmailRequest](docs/PasswordChangeEmailRequest.md) + - [PasswordChangeEmailResponse](docs/PasswordChangeEmailResponse.md) - [PolicyCategory](docs/PolicyCategory.md) - [PolicyExecutionType](docs/PolicyExecutionType.md) - [PolicyRecommendationParams](docs/PolicyRecommendationParams.md) @@ -552,7 +574,7 @@ Class | Method | Description - [ProviderConfigInput](docs/ProviderConfigInput.md) - [ProviderConfigOutput](docs/ProviderConfigOutput.md) - [PublishCustomHierarchyRequest](docs/PublishCustomHierarchyRequest.md) - - [QueryDetails](docs/QueryDetails.md) + - [QueryDetailsDerivedVariables](docs/QueryDetailsDerivedVariables.md) - [QueryFilters](docs/QueryFilters.md) - [QueryOrder](docs/QueryOrder.md) - [RecommendationEngine](docs/RecommendationEngine.md) @@ -560,11 +582,14 @@ Class | Method | Description - [RecommendationEngineRequest](docs/RecommendationEngineRequest.md) - [RecommendationEngineResponse](docs/RecommendationEngineResponse.md) - [RecommendationParams](docs/RecommendationParams.md) + - [RecommendationQueryDetails](docs/RecommendationQueryDetails.md) - [RecommendationTicket](docs/RecommendationTicket.md) - [RecommendationTicketAPIRequestInput](docs/RecommendationTicketAPIRequestInput.md) - [RecommendationTicketAPIRequestOutput](docs/RecommendationTicketAPIRequestOutput.md) - [RecommendationTicketRequest](docs/RecommendationTicketRequest.md) - [RecommendationTicketResponse](docs/RecommendationTicketResponse.md) + - [RecommendationUnit](docs/RecommendationUnit.md) + - [RecommendationUnitFilters](docs/RecommendationUnitFilters.md) - [RelationshipConfigItem](docs/RelationshipConfigItem.md) - [ResourceCatalog](docs/ResourceCatalog.md) - [ResourceCatalogRequest](docs/ResourceCatalogRequest.md) @@ -615,11 +640,13 @@ Class | Method | Description - [ResponseGetTenantProvidersResponse](docs/ResponseGetTenantProvidersResponse.md) - [ResponseGetTenantTicketsResponse](docs/ResponseGetTenantTicketsResponse.md) - [ResponseGetTenantUserByIDResponse](docs/ResponseGetTenantUserByIDResponse.md) + - [ResponseGetTenantUserProfileResponse](docs/ResponseGetTenantUserProfileResponse.md) - [ResponseGetTenantUsersWithFilterResponse](docs/ResponseGetTenantUsersWithFilterResponse.md) - [ResponseGetTenantsResponse](docs/ResponseGetTenantsResponse.md) - [ResponseGetTicketByIdPolicyDetailsResponse](docs/ResponseGetTicketByIdPolicyDetailsResponse.md) - [ResponseOverrideTenantAnomalyConfigResponse](docs/ResponseOverrideTenantAnomalyConfigResponse.md) - [ResponseOverrideTenantPolicyExclusionsResponse](docs/ResponseOverrideTenantPolicyExclusionsResponse.md) + - [ResponsePasswordChangeEmailResponse](docs/ResponsePasswordChangeEmailResponse.md) - [ResponseRecommendationEngineResponse](docs/ResponseRecommendationEngineResponse.md) - [ResponseRecommendationTicketResponse](docs/ResponseRecommendationTicketResponse.md) - [ResponseResourceCatalogResponse](docs/ResponseResourceCatalogResponse.md) @@ -634,11 +661,11 @@ Class | Method | Description - [ResponseUpdateTenantUserDetailsResponse](docs/ResponseUpdateTenantUserDetailsResponse.md) - [ResponseUpdateTenantUserResponse](docs/ResponseUpdateTenantUserResponse.md) - [RuleType](docs/RuleType.md) + - [Service](docs/Service.md) - [ServiceCatalog](docs/ServiceCatalog.md) - [ServiceCatalogRequest](docs/ServiceCatalogRequest.md) - [ServiceCatalogRequestFind](docs/ServiceCatalogRequestFind.md) - [ServiceCatalogResponse](docs/ServiceCatalogResponse.md) - - [ServiceConfig](docs/ServiceConfig.md) - [SetTenantStatusRequest](docs/SetTenantStatusRequest.md) - [SortCriteria](docs/SortCriteria.md) - [Sources](docs/Sources.md) @@ -646,6 +673,7 @@ Class | Method | Description - [Status](docs/Status.md) - [Status1](docs/Status1.md) - [Statuses](docs/Statuses.md) + - [StorageLensConfig](docs/StorageLensConfig.md) - [Tenant](docs/Tenant.md) - [TenantAnomalySettingFilters](docs/TenantAnomalySettingFilters.md) - [TenantAnomalySettings](docs/TenantAnomalySettings.md) @@ -684,6 +712,8 @@ Class | Method | Description - [TimeDimensionOutput](docs/TimeDimensionOutput.md) - [TimeDimensionOutputCompareDateRangeInner](docs/TimeDimensionOutputCompareDateRangeInner.md) - [Timezone](docs/Timezone.md) + - [UpdateActionTypeRequest](docs/UpdateActionTypeRequest.md) + - [UpdateActionTypeResponse](docs/UpdateActionTypeResponse.md) - [UpdateHierarchyNodeAPIRequest](docs/UpdateHierarchyNodeAPIRequest.md) - [UpdateHierarchyNodeRequest](docs/UpdateHierarchyNodeRequest.md) - [UpdateHierarchyNodeResponse](docs/UpdateHierarchyNodeResponse.md) @@ -691,6 +721,8 @@ Class | Method | Description - [UpdateOrganizationResponse](docs/UpdateOrganizationResponse.md) - [UpdatePolicyTemplateRequest](docs/UpdatePolicyTemplateRequest.md) - [UpdatePolicyTemplateResponse](docs/UpdatePolicyTemplateResponse.md) + - [UpdateRecommendationUnitRequest](docs/UpdateRecommendationUnitRequest.md) + - [UpdateRecommendationUnitResponse](docs/UpdateRecommendationUnitResponse.md) - [UpdateTenantPolicySettingLastRunAtRequest](docs/UpdateTenantPolicySettingLastRunAtRequest.md) - [UpdateTenantRequest](docs/UpdateTenantRequest.md) - [UpdateTenantResponse](docs/UpdateTenantResponse.md) diff --git a/docs/ActionType.md b/docs/ActionType.md new file mode 100644 index 00000000..37c0bf0b --- /dev/null +++ b/docs/ActionType.md @@ -0,0 +1,33 @@ +# ActionType + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**service** | [**Service**](Service.md) | | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**id** | **int** | Action Type ID | + +## Example + +```python +from onelens_backend_client.models.action_type import ActionType + +# TODO update the JSON string below +json = "{}" +# create an instance of ActionType from a JSON string +action_type_instance = ActionType.from_json(json) +# print the JSON string representation of the object +print(ActionType.to_json()) + +# convert the object into a dict +action_type_dict = action_type_instance.to_dict() +# create an instance of ActionType from a dict +action_type_form_dict = action_type.from_dict(action_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/ActionTypeFilters.md b/docs/ActionTypeFilters.md new file mode 100644 index 00000000..7a39c9fc --- /dev/null +++ b/docs/ActionTypeFilters.md @@ -0,0 +1,31 @@ +# ActionTypeFilters + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**search_query** | **str** | | [optional] +**ids** | **List[int]** | Filter by recommendation unit id/alias. | [optional] [default to []] +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | Filter by Services | [optional] [default to []] + +## Example + +```python +from onelens_backend_client.models.action_type_filters import ActionTypeFilters + +# TODO update the JSON string below +json = "{}" +# create an instance of ActionTypeFilters from a JSON string +action_type_filters_instance = ActionTypeFilters.from_json(json) +# print the JSON string representation of the object +print(ActionTypeFilters.to_json()) + +# convert the object into a dict +action_type_filters_dict = action_type_filters_instance.to_dict() +# create an instance of ActionTypeFilters from a dict +action_type_filters_form_dict = action_type_filters.from_dict(action_type_filters_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ActionTypeFiltersServicesInner.md b/docs/ActionTypeFiltersServicesInner.md new file mode 100644 index 00000000..9ef55a09 --- /dev/null +++ b/docs/ActionTypeFiltersServicesInner.md @@ -0,0 +1,28 @@ +# ActionTypeFiltersServicesInner + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +## Example + +```python +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner + +# TODO update the JSON string below +json = "{}" +# create an instance of ActionTypeFiltersServicesInner from a JSON string +action_type_filters_services_inner_instance = ActionTypeFiltersServicesInner.from_json(json) +# print the JSON string representation of the object +print(ActionTypeFiltersServicesInner.to_json()) + +# convert the object into a dict +action_type_filters_services_inner_dict = action_type_filters_services_inner_instance.to_dict() +# create an instance of ActionTypeFiltersServicesInner from a dict +action_type_filters_services_inner_form_dict = action_type_filters_services_inner.from_dict(action_type_filters_services_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/CreateActionTypeRequest.md b/docs/CreateActionTypeRequest.md new file mode 100644 index 00000000..4fbff5c5 --- /dev/null +++ b/docs/CreateActionTypeRequest.md @@ -0,0 +1,32 @@ +# CreateActionTypeRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**service** | [**Service**](Service.md) | | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | + +## Example + +```python +from onelens_backend_client.models.create_action_type_request import CreateActionTypeRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CreateActionTypeRequest from a JSON string +create_action_type_request_instance = CreateActionTypeRequest.from_json(json) +# print the JSON string representation of the object +print(CreateActionTypeRequest.to_json()) + +# convert the object into a dict +create_action_type_request_dict = create_action_type_request_instance.to_dict() +# create an instance of CreateActionTypeRequest from a dict +create_action_type_request_form_dict = create_action_type_request.from_dict(create_action_type_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CreateActionTypeResponse.md b/docs/CreateActionTypeResponse.md new file mode 100644 index 00000000..0ac0e7c1 --- /dev/null +++ b/docs/CreateActionTypeResponse.md @@ -0,0 +1,33 @@ +# CreateActionTypeResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**service** | [**Service**](Service.md) | | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**id** | **int** | Action Type ID | + +## Example + +```python +from onelens_backend_client.models.create_action_type_response import CreateActionTypeResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of CreateActionTypeResponse from a JSON string +create_action_type_response_instance = CreateActionTypeResponse.from_json(json) +# print the JSON string representation of the object +print(CreateActionTypeResponse.to_json()) + +# convert the object into a dict +create_action_type_response_dict = create_action_type_response_instance.to_dict() +# create an instance of CreateActionTypeResponse from a dict +create_action_type_response_form_dict = create_action_type_response.from_dict(create_action_type_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/CreatePolicyTemplateRequest.md b/docs/CreatePolicyTemplateRequest.md index 01322172..6823f8dd 100644 --- a/docs/CreatePolicyTemplateRequest.md +++ b/docs/CreatePolicyTemplateRequest.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **title** | **str** | The title of the policy template. | **alias** | **str** | The alias of the policy template. | **description** | **str** | The description of the policy template. | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | The list of services associated the policy template. | +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | The list of services associated the policy template. | **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | The execution type of the policy template. | **details** | [**PolicyTemplateDetailsInput**](PolicyTemplateDetailsInput.md) | The details of the policy template. | **description2** | **str** | The description2 of the policy template. | [optional] diff --git a/docs/CreatePolicyTemplateResponse.md b/docs/CreatePolicyTemplateResponse.md index 28bd8c63..8f094efa 100644 --- a/docs/CreatePolicyTemplateResponse.md +++ b/docs/CreatePolicyTemplateResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **title** | **str** | The title of the policy template. | **alias** | **str** | The alias of the policy template. | **description** | **str** | The description of the policy template. | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | The list of services associated the policy template. | +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | The list of services associated the policy template. | **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | The execution type of the policy template. | **details** | [**PolicyTemplateDetailsOutput**](PolicyTemplateDetailsOutput.md) | The details of the policy template. | **description2** | **str** | The description2 of the policy template. | [optional] diff --git a/docs/CreateRecommendationUnitRequest.md b/docs/CreateRecommendationUnitRequest.md new file mode 100644 index 00000000..fc6869c0 --- /dev/null +++ b/docs/CreateRecommendationUnitRequest.md @@ -0,0 +1,37 @@ +# CreateRecommendationUnitRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | Recommendation Config ID | +**service** | **str** | Service AWS etc. | +**action_type_id** | **int** | | [optional] +**priority** | **int** | Priority | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**effort** | [**Effort**](Effort.md) | Effort | +**query_details** | [**RecommendationQueryDetails**](RecommendationQueryDetails.md) | | + +## Example + +```python +from onelens_backend_client.models.create_recommendation_unit_request import CreateRecommendationUnitRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CreateRecommendationUnitRequest from a JSON string +create_recommendation_unit_request_instance = CreateRecommendationUnitRequest.from_json(json) +# print the JSON string representation of the object +print(CreateRecommendationUnitRequest.to_json()) + +# convert the object into a dict +create_recommendation_unit_request_dict = create_recommendation_unit_request_instance.to_dict() +# create an instance of CreateRecommendationUnitRequest from a dict +create_recommendation_unit_request_form_dict = create_recommendation_unit_request.from_dict(create_recommendation_unit_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CreateRecommendationUnitResponse.md b/docs/CreateRecommendationUnitResponse.md new file mode 100644 index 00000000..6efe666f --- /dev/null +++ b/docs/CreateRecommendationUnitResponse.md @@ -0,0 +1,37 @@ +# CreateRecommendationUnitResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | Recommendation Config ID | +**service** | **str** | Service AWS etc. | +**action_type_id** | **int** | | [optional] +**priority** | **int** | Priority | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**effort** | [**Effort**](Effort.md) | Effort | +**query_details** | [**RecommendationQueryDetails**](RecommendationQueryDetails.md) | | + +## Example + +```python +from onelens_backend_client.models.create_recommendation_unit_response import CreateRecommendationUnitResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of CreateRecommendationUnitResponse from a JSON string +create_recommendation_unit_response_instance = CreateRecommendationUnitResponse.from_json(json) +# print the JSON string representation of the object +print(CreateRecommendationUnitResponse.to_json()) + +# convert the object into a dict +create_recommendation_unit_response_dict = create_recommendation_unit_response_instance.to_dict() +# create an instance of CreateRecommendationUnitResponse from a dict +create_recommendation_unit_response_form_dict = create_recommendation_unit_response.from_dict(create_recommendation_unit_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/GetActionTypeRequest.md b/docs/GetActionTypeRequest.md new file mode 100644 index 00000000..a4b02163 --- /dev/null +++ b/docs/GetActionTypeRequest.md @@ -0,0 +1,30 @@ +# GetActionTypeRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**PaginationParams**](PaginationParams.md) | Pagination parameters for the request. | [optional] +**filters** | [**ActionTypeFilters**](ActionTypeFilters.md) | Filters to apply to the Action Types. | [optional] + +## Example + +```python +from onelens_backend_client.models.get_action_type_request import GetActionTypeRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GetActionTypeRequest from a JSON string +get_action_type_request_instance = GetActionTypeRequest.from_json(json) +# print the JSON string representation of the object +print(GetActionTypeRequest.to_json()) + +# convert the object into a dict +get_action_type_request_dict = get_action_type_request_instance.to_dict() +# create an instance of GetActionTypeRequest from a dict +get_action_type_request_form_dict = get_action_type_request.from_dict(get_action_type_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GetActionTypeResponse.md b/docs/GetActionTypeResponse.md new file mode 100644 index 00000000..dd2471f7 --- /dev/null +++ b/docs/GetActionTypeResponse.md @@ -0,0 +1,30 @@ +# GetActionTypeResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**action_types** | [**List[ActionType]**](ActionType.md) | Action Types | +**pagination** | [**PaginationFields**](PaginationFields.md) | Pagination fields | + +## Example + +```python +from onelens_backend_client.models.get_action_type_response import GetActionTypeResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of GetActionTypeResponse from a JSON string +get_action_type_response_instance = GetActionTypeResponse.from_json(json) +# print the JSON string representation of the object +print(GetActionTypeResponse.to_json()) + +# convert the object into a dict +get_action_type_response_dict = get_action_type_response_instance.to_dict() +# create an instance of GetActionTypeResponse from a dict +get_action_type_response_form_dict = get_action_type_response.from_dict(get_action_type_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/GetPolicyTemplateByIDResponse.md b/docs/GetPolicyTemplateByIDResponse.md index 01e39e92..f4a2091e 100644 --- a/docs/GetPolicyTemplateByIDResponse.md +++ b/docs/GetPolicyTemplateByIDResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **title** | **str** | The title of the policy template. | **alias** | **str** | The alias of the policy template. | **description** | **str** | The description of the policy template. | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | The list of services associated the policy template. | +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | The list of services associated the policy template. | **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | The execution type of the policy template. | **details** | [**PolicyTemplateDetailsOutput**](PolicyTemplateDetailsOutput.md) | The details of the policy template. | **description2** | **str** | The description2 of the policy template. | [optional] diff --git a/docs/GetRecommendationUnitByIdResponse.md b/docs/GetRecommendationUnitByIdResponse.md index 981ea687..df49f3a1 100644 --- a/docs/GetRecommendationUnitByIdResponse.md +++ b/docs/GetRecommendationUnitByIdResponse.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**recommendation_unit** | [**ServiceConfig**](ServiceConfig.md) | Recommendation Unit | +**recommendation_unit** | [**RecommendationUnit**](RecommendationUnit.md) | Recommendation Unit | ## Example diff --git a/docs/GetRecommendationUnitRequest.md b/docs/GetRecommendationUnitRequest.md new file mode 100644 index 00000000..7d12d517 --- /dev/null +++ b/docs/GetRecommendationUnitRequest.md @@ -0,0 +1,30 @@ +# GetRecommendationUnitRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**PaginationParams**](PaginationParams.md) | Pagination parameters for the request. | [optional] +**filters** | [**RecommendationUnitFilters**](RecommendationUnitFilters.md) | Filters to apply to the Recommendation Unit. | [optional] + +## Example + +```python +from onelens_backend_client.models.get_recommendation_unit_request import GetRecommendationUnitRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GetRecommendationUnitRequest from a JSON string +get_recommendation_unit_request_instance = GetRecommendationUnitRequest.from_json(json) +# print the JSON string representation of the object +print(GetRecommendationUnitRequest.to_json()) + +# convert the object into a dict +get_recommendation_unit_request_dict = get_recommendation_unit_request_instance.to_dict() +# create an instance of GetRecommendationUnitRequest from a dict +get_recommendation_unit_request_form_dict = get_recommendation_unit_request.from_dict(get_recommendation_unit_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GetRecommendationUnitsResponse.md b/docs/GetRecommendationUnitsResponse.md index 28caf2a6..0b39a11e 100644 --- a/docs/GetRecommendationUnitsResponse.md +++ b/docs/GetRecommendationUnitsResponse.md @@ -5,7 +5,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**recommendation_units** | [**List[ServiceConfig]**](ServiceConfig.md) | Recommendation Unit | +**recommendation_units** | [**List[RecommendationUnit]**](RecommendationUnit.md) | Recommendation Unit | +**pagination** | [**PaginationFields**](PaginationFields.md) | Pagination fields | ## Example diff --git a/docs/GetTenantPoliciesWithSettingsAPIRequest.md b/docs/GetTenantPoliciesWithSettingsAPIRequest.md index 7d11b13c..b7cdb4dc 100644 --- a/docs/GetTenantPoliciesWithSettingsAPIRequest.md +++ b/docs/GetTenantPoliciesWithSettingsAPIRequest.md @@ -7,6 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **pagination** | [**PaginationParams**](PaginationParams.md) | Pagination parameters for the request. | [optional] **filters** | [**List[OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria]**](OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria.md) | Filters to be applied | +**sort_criteria** | [**SortCriteria**](SortCriteria.md) | | [optional] ## Example diff --git a/docs/GetTenantPoliciesWithSettingsRequest.md b/docs/GetTenantPoliciesWithSettingsRequest.md index de5d5a77..55d7f8a0 100644 --- a/docs/GetTenantPoliciesWithSettingsRequest.md +++ b/docs/GetTenantPoliciesWithSettingsRequest.md @@ -7,6 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **pagination** | [**PaginationParams**](PaginationParams.md) | Pagination parameters for the request. | [optional] **filters** | [**List[OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria]**](OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria.md) | Filters to be applied | +**sort_criteria** | [**SortCriteria**](SortCriteria.md) | | [optional] **tenant_id** | **str** | The id of the tenant. | ## Example diff --git a/docs/GetTenantPolicyByIdResponse.md b/docs/GetTenantPolicyByIdResponse.md index 14c77e5d..d583379f 100644 --- a/docs/GetTenantPolicyByIdResponse.md +++ b/docs/GetTenantPolicyByIdResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **title** | **str** | The title of the policy template. | **alias** | **str** | The alias of the policy template. | **description** | **str** | The description of the policy template. | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | The list of services associated the policy template. | +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | The list of services associated the policy template. | **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | The execution type of the policy template. | **details** | [**PolicyTemplateDetailsOutput**](PolicyTemplateDetailsOutput.md) | The details of the policy template. | **description2** | **str** | The description2 of the policy template. | [optional] diff --git a/docs/GetTenantUserProfileResponse.md b/docs/GetTenantUserProfileResponse.md new file mode 100644 index 00000000..64632583 --- /dev/null +++ b/docs/GetTenantUserProfileResponse.md @@ -0,0 +1,51 @@ +# GetTenantUserProfileResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**profile_pic_url** | [**ProfilePicUrl**](ProfilePicUrl.md) | | [optional] +**last_login** | [**LastLogin**](LastLogin.md) | | [optional] +**status** | [**UserStatus**](UserStatus.md) | Status of the user like ACTIVE, BLOCKED etc. | [optional] +**first_name** | [**FirstName**](FirstName.md) | | +**middle_name** | [**MiddleName**](MiddleName.md) | | [optional] +**last_name** | [**LastName**](LastName.md) | | +**email** | [**Email**](Email.md) | | [optional] +**mobile_country_code** | [**MobileCountryCode**](MobileCountryCode.md) | | [optional] +**mobile_number** | [**MobileNumber**](MobileNumber.md) | | [optional] +**persona** | [**CreateTenantUserRequestPersona**](CreateTenantUserRequestPersona.md) | | [optional] +**role** | [**UserRole**](UserRole.md) | Role of the user in the tenant | [optional] +**job_title** | [**JobTitle**](JobTitle.md) | | [optional] +**manager** | [**Manager**](Manager.md) | | [optional] +**city** | [**City**](City.md) | | [optional] +**state** | [**State**](State.md) | | [optional] +**country** | [**Country**](Country.md) | | [optional] +**display_language** | [**DisplayLanguage**](DisplayLanguage.md) | | [optional] +**preferred_currency** | [**PreferredCurrency**](PreferredCurrency.md) | | [optional] +**timezone** | [**Timezone**](Timezone.md) | | [optional] +**display_date_format** | [**DisplayDateFormat**](DisplayDateFormat.md) | | [optional] +**display_time_format** | [**DisplayTimeFormat**](DisplayTimeFormat.md) | | [optional] +**sources** | [**Sources**](Sources.md) | | [optional] +**ol_user_id** | **object** | Unique onelens identifier for the user | + +## Example + +```python +from onelens_backend_client.models.get_tenant_user_profile_response import GetTenantUserProfileResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of GetTenantUserProfileResponse from a JSON string +get_tenant_user_profile_response_instance = GetTenantUserProfileResponse.from_json(json) +# print the JSON string representation of the object +print(GetTenantUserProfileResponse.to_json()) + +# convert the object into a dict +get_tenant_user_profile_response_dict = get_tenant_user_profile_response_instance.to_dict() +# create an instance of GetTenantUserProfileResponse from a dict +get_tenant_user_profile_response_form_dict = get_tenant_user_profile_response.from_dict(get_tenant_user_profile_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/PasswordChangeEmailRequest.md b/docs/PasswordChangeEmailRequest.md new file mode 100644 index 00000000..aff4ea1d --- /dev/null +++ b/docs/PasswordChangeEmailRequest.md @@ -0,0 +1,30 @@ +# PasswordChangeEmailRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ol_user_id** | **str** | Unique onelens identifier for the user | +**tenant_id** | **str** | The unique identifier of the tenant | + +## Example + +```python +from onelens_backend_client.models.password_change_email_request import PasswordChangeEmailRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordChangeEmailRequest from a JSON string +password_change_email_request_instance = PasswordChangeEmailRequest.from_json(json) +# print the JSON string representation of the object +print(PasswordChangeEmailRequest.to_json()) + +# convert the object into a dict +password_change_email_request_dict = password_change_email_request_instance.to_dict() +# create an instance of PasswordChangeEmailRequest from a dict +password_change_email_request_form_dict = password_change_email_request.from_dict(password_change_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/PasswordChangeEmailResponse.md b/docs/PasswordChangeEmailResponse.md new file mode 100644 index 00000000..76ead014 --- /dev/null +++ b/docs/PasswordChangeEmailResponse.md @@ -0,0 +1,29 @@ +# PasswordChangeEmailResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**message** | **str** | Message for password change email response | + +## Example + +```python +from onelens_backend_client.models.password_change_email_response import PasswordChangeEmailResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordChangeEmailResponse from a JSON string +password_change_email_response_instance = PasswordChangeEmailResponse.from_json(json) +# print the JSON string representation of the object +print(PasswordChangeEmailResponse.to_json()) + +# convert the object into a dict +password_change_email_response_dict = password_change_email_response_instance.to_dict() +# create an instance of PasswordChangeEmailResponse from a dict +password_change_email_response_form_dict = password_change_email_response.from_dict(password_change_email_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/PolicyTemplate.md b/docs/PolicyTemplate.md index 6f093b8e..ef2d44b2 100644 --- a/docs/PolicyTemplate.md +++ b/docs/PolicyTemplate.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **title** | **str** | The title of the policy template. | **alias** | **str** | The alias of the policy template. | **description** | **str** | The description of the policy template. | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | The list of services associated the policy template. | +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | The list of services associated the policy template. | **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | The execution type of the policy template. | **details** | [**PolicyTemplateDetailsOutput**](PolicyTemplateDetailsOutput.md) | The details of the policy template. | **description2** | **str** | The description2 of the policy template. | [optional] diff --git a/docs/PolicyTemplateFilters.md b/docs/PolicyTemplateFilters.md index dcf42ac6..960625af 100644 --- a/docs/PolicyTemplateFilters.md +++ b/docs/PolicyTemplateFilters.md @@ -10,7 +10,7 @@ Name | Type | Description | Notes **states** | [**List[PolicyTemplateState]**](PolicyTemplateState.md) | Filter by state. Default is ACTIVE. | [optional] [default to [ACTIVE]] **categories** | [**List[PolicyCategory]**](PolicyCategory.md) | Filter by type. | [optional] [default to []] **providers** | [**List[Provider]**](Provider.md) | Filter by provider. | [optional] [default to []] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | Filter by services. | [optional] [default to []] +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | Filter by services. | [optional] [default to []] **execution_types** | [**List[PolicyExecutionType]**](PolicyExecutionType.md) | Filter by execution type. | [optional] [default to []] ## Example diff --git a/docs/PolicyTemplateUpdateFieldsMixin.md b/docs/PolicyTemplateUpdateFieldsMixin.md index 3307f17e..763d4dfa 100644 --- a/docs/PolicyTemplateUpdateFieldsMixin.md +++ b/docs/PolicyTemplateUpdateFieldsMixin.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **title** | **str** | | [optional] **description** | **str** | | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | | [optional] +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | | [optional] **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | | [optional] **details** | [**PolicyTemplateDetailsInput**](PolicyTemplateDetailsInput.md) | | [optional] **description2** | **str** | | [optional] diff --git a/docs/ProviderConfigInput.md b/docs/ProviderConfigInput.md index 78ad577c..088b28d8 100644 --- a/docs/ProviderConfigInput.md +++ b/docs/ProviderConfigInput.md @@ -8,6 +8,7 @@ Name | Type | Description | Notes **regions** | **object** | | [optional] **role_name** | **str** | | [optional] **cur_bucket_config** | [**CurBucketConfig**](CurBucketConfig.md) | | [optional] +**storage_lens_config** | [**StorageLensConfig**](StorageLensConfig.md) | | [optional] ## Example diff --git a/docs/ProviderConfigOutput.md b/docs/ProviderConfigOutput.md index a178ab14..a2b0d8e3 100644 --- a/docs/ProviderConfigOutput.md +++ b/docs/ProviderConfigOutput.md @@ -8,6 +8,7 @@ Name | Type | Description | Notes **regions** | **object** | | [optional] **role_name** | **str** | | [optional] **cur_bucket_config** | [**CurBucketConfig**](CurBucketConfig.md) | | [optional] +**storage_lens_config** | [**StorageLensConfig**](StorageLensConfig.md) | | [optional] ## Example diff --git a/docs/QueryDetailsDerivedVariables.md b/docs/QueryDetailsDerivedVariables.md new file mode 100644 index 00000000..9e76a810 --- /dev/null +++ b/docs/QueryDetailsDerivedVariables.md @@ -0,0 +1,31 @@ +# QueryDetailsDerivedVariables + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**key** | **str** | Key | +**value_type** | **str** | Value Type | +**source_key** | **str** | Source Key | + +## Example + +```python +from onelens_backend_client.models.query_details_derived_variables import QueryDetailsDerivedVariables + +# TODO update the JSON string below +json = "{}" +# create an instance of QueryDetailsDerivedVariables from a JSON string +query_details_derived_variables_instance = QueryDetailsDerivedVariables.from_json(json) +# print the JSON string representation of the object +print(QueryDetailsDerivedVariables.to_json()) + +# convert the object into a dict +query_details_derived_variables_dict = query_details_derived_variables_instance.to_dict() +# create an instance of QueryDetailsDerivedVariables from a dict +query_details_derived_variables_form_dict = query_details_derived_variables.from_dict(query_details_derived_variables_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RecommendationEngineServiceApi.md b/docs/RecommendationEngineServiceApi.md index d86b69eb..017cb11a 100644 --- a/docs/RecommendationEngineServiceApi.md +++ b/docs/RecommendationEngineServiceApi.md @@ -4,23 +4,24 @@ All URIs are relative to *http://localhost* Method | Description ------------- | ------------- -[**get_recommendation_unit_by_id**](RecommendationEngineServiceApi.md#get_recommendation_unit_by_id) | Retrieves all Tenants with filters. -[**get_recommendation_units**](RecommendationEngineServiceApi.md#get_recommendation_units) | Retrieves all recommendation units by filter +[**create_action_type**](RecommendationEngineServiceApi.md#create_action_type) | Create Action Type +[**get_action_types**](RecommendationEngineServiceApi.md#get_action_types) | Get Action Types [**get_recommendations**](RecommendationEngineServiceApi.md#get_recommendations) | Get recommendations. +[**update_action_type**](RecommendationEngineServiceApi.md#update_action_type) | Update Action Type -# **get_recommendation_unit_by_id** -> GetRecommendationUnitByIdResponse get_recommendation_unit_by_id(get_recommendation_unit_by_id_request) +# **create_action_type** +> CreateActionTypeResponse create_action_type(create_action_type_request) -Retrieves all Tenants with filters. +Create Action Type ### Example ```python import onelens_backend_client -from onelens_backend_client.models.get_recommendation_unit_by_id_request import GetRecommendationUnitByIdRequest -from onelens_backend_client.models.get_recommendation_unit_by_id_response import GetRecommendationUnitByIdResponse +from onelens_backend_client.models.create_action_type_request import CreateActionTypeRequest +from onelens_backend_client.models.create_action_type_response import CreateActionTypeResponse from onelens_backend_client.rest import ApiException from pprint import pprint @@ -35,15 +36,15 @@ configuration = onelens_backend_client.Configuration( with onelens_backend_client.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = onelens_backend_client.RecommendationEngineServiceApi(api_client) - get_recommendation_unit_by_id_request = onelens_backend_client.GetRecommendationUnitByIdRequest() # GetRecommendationUnitByIdRequest | + create_action_type_request = onelens_backend_client.CreateActionTypeRequest() # CreateActionTypeRequest | try: - # Retrieves all Tenants with filters. - api_response = api_instance.get_recommendation_unit_by_id(get_recommendation_unit_by_id_request) - print("The response of RecommendationEngineServiceApi->get_recommendation_unit_by_id:\n") + # Create Action Type + api_response = api_instance.create_action_type(create_action_type_request) + print("The response of RecommendationEngineServiceApi->create_action_type:\n") pprint(api_response) except Exception as e: - print("Exception when calling RecommendationEngineServiceApi->get_recommendation_unit_by_id: %s\n" % e) + print("Exception when calling RecommendationEngineServiceApi->create_action_type: %s\n" % e) ``` @@ -53,11 +54,11 @@ with onelens_backend_client.ApiClient(configuration) as api_client: Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **get_recommendation_unit_by_id_request** | [**GetRecommendationUnitByIdRequest**](GetRecommendationUnitByIdRequest.md)| | + **create_action_type_request** | [**CreateActionTypeRequest**](CreateActionTypeRequest.md)| | ### Return type -[**GetRecommendationUnitByIdResponse**](GetRecommendationUnitByIdResponse.md) +[**CreateActionTypeResponse**](CreateActionTypeResponse.md) ### Authorization @@ -77,18 +78,18 @@ No authorization required [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) -# **get_recommendation_units** -> GetRecommendationUnitsResponse get_recommendation_units(get_recommendation_units_request) +# **get_action_types** +> GetActionTypeResponse get_action_types(get_action_type_request) -Retrieves all recommendation units by filter +Get Action Types ### Example ```python import onelens_backend_client -from onelens_backend_client.models.get_recommendation_units_request import GetRecommendationUnitsRequest -from onelens_backend_client.models.get_recommendation_units_response import GetRecommendationUnitsResponse +from onelens_backend_client.models.get_action_type_request import GetActionTypeRequest +from onelens_backend_client.models.get_action_type_response import GetActionTypeResponse from onelens_backend_client.rest import ApiException from pprint import pprint @@ -103,15 +104,15 @@ configuration = onelens_backend_client.Configuration( with onelens_backend_client.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = onelens_backend_client.RecommendationEngineServiceApi(api_client) - get_recommendation_units_request = onelens_backend_client.GetRecommendationUnitsRequest() # GetRecommendationUnitsRequest | + get_action_type_request = onelens_backend_client.GetActionTypeRequest() # GetActionTypeRequest | try: - # Retrieves all recommendation units by filter - api_response = api_instance.get_recommendation_units(get_recommendation_units_request) - print("The response of RecommendationEngineServiceApi->get_recommendation_units:\n") + # Get Action Types + api_response = api_instance.get_action_types(get_action_type_request) + print("The response of RecommendationEngineServiceApi->get_action_types:\n") pprint(api_response) except Exception as e: - print("Exception when calling RecommendationEngineServiceApi->get_recommendation_units: %s\n" % e) + print("Exception when calling RecommendationEngineServiceApi->get_action_types: %s\n" % e) ``` @@ -121,11 +122,11 @@ with onelens_backend_client.ApiClient(configuration) as api_client: Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **get_recommendation_units_request** | [**GetRecommendationUnitsRequest**](GetRecommendationUnitsRequest.md)| | + **get_action_type_request** | [**GetActionTypeRequest**](GetActionTypeRequest.md)| | ### Return type -[**GetRecommendationUnitsResponse**](GetRecommendationUnitsResponse.md) +[**GetActionTypeResponse**](GetActionTypeResponse.md) ### Authorization @@ -213,3 +214,71 @@ No authorization required [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **update_action_type** +> UpdateActionTypeResponse update_action_type(update_action_type_request) + +Update Action Type + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.update_action_type_request import UpdateActionTypeRequest +from onelens_backend_client.models.update_action_type_response import UpdateActionTypeResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.RecommendationEngineServiceApi(api_client) + update_action_type_request = onelens_backend_client.UpdateActionTypeRequest() # UpdateActionTypeRequest | + + try: + # Update Action Type + api_response = api_instance.update_action_type(update_action_type_request) + print("The response of RecommendationEngineServiceApi->update_action_type:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RecommendationEngineServiceApi->update_action_type: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **update_action_type_request** | [**UpdateActionTypeRequest**](UpdateActionTypeRequest.md)| | + +### Return type + +[**UpdateActionTypeResponse**](UpdateActionTypeResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[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/RecommendationQueryDetails.md b/docs/RecommendationQueryDetails.md new file mode 100644 index 00000000..65249f9d --- /dev/null +++ b/docs/RecommendationQueryDetails.md @@ -0,0 +1,30 @@ +# RecommendationQueryDetails + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**derived_variables** | [**List[QueryDetailsDerivedVariables]**](QueryDetailsDerivedVariables.md) | Actual | +**query** | **str** | Sql Query to get the recommendation | + +## Example + +```python +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails + +# TODO update the JSON string below +json = "{}" +# create an instance of RecommendationQueryDetails from a JSON string +recommendation_query_details_instance = RecommendationQueryDetails.from_json(json) +# print the JSON string representation of the object +print(RecommendationQueryDetails.to_json()) + +# convert the object into a dict +recommendation_query_details_dict = recommendation_query_details_instance.to_dict() +# create an instance of RecommendationQueryDetails from a dict +recommendation_query_details_form_dict = recommendation_query_details.from_dict(recommendation_query_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/RecommendationUnit.md b/docs/RecommendationUnit.md new file mode 100644 index 00000000..73e54cfd --- /dev/null +++ b/docs/RecommendationUnit.md @@ -0,0 +1,37 @@ +# RecommendationUnit + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | Recommendation Config ID | +**service** | **str** | Service AWS etc. | +**action_type_id** | **int** | | [optional] +**priority** | **int** | Priority | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**effort** | [**Effort**](Effort.md) | Effort | +**query_details** | [**RecommendationQueryDetails**](RecommendationQueryDetails.md) | | + +## Example + +```python +from onelens_backend_client.models.recommendation_unit import RecommendationUnit + +# TODO update the JSON string below +json = "{}" +# create an instance of RecommendationUnit from a JSON string +recommendation_unit_instance = RecommendationUnit.from_json(json) +# print the JSON string representation of the object +print(RecommendationUnit.to_json()) + +# convert the object into a dict +recommendation_unit_dict = recommendation_unit_instance.to_dict() +# create an instance of RecommendationUnit from a dict +recommendation_unit_form_dict = recommendation_unit.from_dict(recommendation_unit_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RecommendationUnitFilters.md b/docs/RecommendationUnitFilters.md new file mode 100644 index 00000000..46cc50b8 --- /dev/null +++ b/docs/RecommendationUnitFilters.md @@ -0,0 +1,34 @@ +# RecommendationUnitFilters + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**search_query** | **str** | | [optional] +**ids** | **List[str]** | Filter by recommendation unit id/alias. | [optional] [default to []] +**services** | **List[str]** | Filter by Services | [optional] [default to []] +**action_type_ids** | **List[int]** | Filter by action type. | [optional] [default to []] +**priorities** | **List[int]** | Filter by priorities. | [optional] [default to []] +**efforts** | [**List[Effort]**](Effort.md) | Filter by effort. | [optional] [default to []] + +## Example + +```python +from onelens_backend_client.models.recommendation_unit_filters import RecommendationUnitFilters + +# TODO update the JSON string below +json = "{}" +# create an instance of RecommendationUnitFilters from a JSON string +recommendation_unit_filters_instance = RecommendationUnitFilters.from_json(json) +# print the JSON string representation of the object +print(RecommendationUnitFilters.to_json()) + +# convert the object into a dict +recommendation_unit_filters_dict = recommendation_unit_filters_instance.to_dict() +# create an instance of RecommendationUnitFilters from a dict +recommendation_unit_filters_form_dict = recommendation_unit_filters.from_dict(recommendation_unit_filters_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RecommendationUnitServiceApi.md b/docs/RecommendationUnitServiceApi.md new file mode 100644 index 00000000..4658bced --- /dev/null +++ b/docs/RecommendationUnitServiceApi.md @@ -0,0 +1,284 @@ +# RecommendationUnitServiceApi + +All URIs are relative to *http://localhost* + +Method | Description +------------- | ------------- +[**create_recommendation_unit**](RecommendationUnitServiceApi.md#create_recommendation_unit) | Create recommendation unit +[**get_recommendation_unit_by_id**](RecommendationUnitServiceApi.md#get_recommendation_unit_by_id) | Retrieves Recommendation unit ID. +[**get_recommendation_units**](RecommendationUnitServiceApi.md#get_recommendation_units) | Retrieves all recommendation units with filters +[**update_recommendation_unit**](RecommendationUnitServiceApi.md#update_recommendation_unit) | Update recommendation unit + + +# **create_recommendation_unit** +> CreateRecommendationUnitResponse create_recommendation_unit(create_recommendation_unit_request) + +Create recommendation unit + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.create_recommendation_unit_request import CreateRecommendationUnitRequest +from onelens_backend_client.models.create_recommendation_unit_response import CreateRecommendationUnitResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.RecommendationUnitServiceApi(api_client) + create_recommendation_unit_request = onelens_backend_client.CreateRecommendationUnitRequest() # CreateRecommendationUnitRequest | + + try: + # Create recommendation unit + api_response = api_instance.create_recommendation_unit(create_recommendation_unit_request) + print("The response of RecommendationUnitServiceApi->create_recommendation_unit:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RecommendationUnitServiceApi->create_recommendation_unit: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **create_recommendation_unit_request** | [**CreateRecommendationUnitRequest**](CreateRecommendationUnitRequest.md)| | + +### Return type + +[**CreateRecommendationUnitResponse**](CreateRecommendationUnitResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **get_recommendation_unit_by_id** +> GetRecommendationUnitByIdResponse get_recommendation_unit_by_id(get_recommendation_unit_by_id_request) + +Retrieves Recommendation unit ID. + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.get_recommendation_unit_by_id_request import GetRecommendationUnitByIdRequest +from onelens_backend_client.models.get_recommendation_unit_by_id_response import GetRecommendationUnitByIdResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.RecommendationUnitServiceApi(api_client) + get_recommendation_unit_by_id_request = onelens_backend_client.GetRecommendationUnitByIdRequest() # GetRecommendationUnitByIdRequest | + + try: + # Retrieves Recommendation unit ID. + api_response = api_instance.get_recommendation_unit_by_id(get_recommendation_unit_by_id_request) + print("The response of RecommendationUnitServiceApi->get_recommendation_unit_by_id:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RecommendationUnitServiceApi->get_recommendation_unit_by_id: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **get_recommendation_unit_by_id_request** | [**GetRecommendationUnitByIdRequest**](GetRecommendationUnitByIdRequest.md)| | + +### Return type + +[**GetRecommendationUnitByIdResponse**](GetRecommendationUnitByIdResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **get_recommendation_units** +> GetRecommendationUnitsResponse get_recommendation_units(get_recommendation_unit_request) + +Retrieves all recommendation units with filters + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.get_recommendation_unit_request import GetRecommendationUnitRequest +from onelens_backend_client.models.get_recommendation_units_response import GetRecommendationUnitsResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.RecommendationUnitServiceApi(api_client) + get_recommendation_unit_request = onelens_backend_client.GetRecommendationUnitRequest() # GetRecommendationUnitRequest | + + try: + # Retrieves all recommendation units with filters + api_response = api_instance.get_recommendation_units(get_recommendation_unit_request) + print("The response of RecommendationUnitServiceApi->get_recommendation_units:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RecommendationUnitServiceApi->get_recommendation_units: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **get_recommendation_unit_request** | [**GetRecommendationUnitRequest**](GetRecommendationUnitRequest.md)| | + +### Return type + +[**GetRecommendationUnitsResponse**](GetRecommendationUnitsResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **update_recommendation_unit** +> UpdateRecommendationUnitResponse update_recommendation_unit(update_recommendation_unit_request) + +Update recommendation unit + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.update_recommendation_unit_request import UpdateRecommendationUnitRequest +from onelens_backend_client.models.update_recommendation_unit_response import UpdateRecommendationUnitResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.RecommendationUnitServiceApi(api_client) + update_recommendation_unit_request = onelens_backend_client.UpdateRecommendationUnitRequest() # UpdateRecommendationUnitRequest | + + try: + # Update recommendation unit + api_response = api_instance.update_recommendation_unit(update_recommendation_unit_request) + print("The response of RecommendationUnitServiceApi->update_recommendation_unit:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RecommendationUnitServiceApi->update_recommendation_unit: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **update_recommendation_unit_request** | [**UpdateRecommendationUnitRequest**](UpdateRecommendationUnitRequest.md)| | + +### Return type + +[**UpdateRecommendationUnitResponse**](UpdateRecommendationUnitResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[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/ResponseGetTenantUserProfileResponse.md b/docs/ResponseGetTenantUserProfileResponse.md new file mode 100644 index 00000000..e4edcf09 --- /dev/null +++ b/docs/ResponseGetTenantUserProfileResponse.md @@ -0,0 +1,30 @@ +# ResponseGetTenantUserProfileResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**GetTenantUserProfileResponse**](GetTenantUserProfileResponse.md) | | +**message** | **str** | | [optional] + +## Example + +```python +from onelens_backend_client.models.response_get_tenant_user_profile_response import ResponseGetTenantUserProfileResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of ResponseGetTenantUserProfileResponse from a JSON string +response_get_tenant_user_profile_response_instance = ResponseGetTenantUserProfileResponse.from_json(json) +# print the JSON string representation of the object +print(ResponseGetTenantUserProfileResponse.to_json()) + +# convert the object into a dict +response_get_tenant_user_profile_response_dict = response_get_tenant_user_profile_response_instance.to_dict() +# create an instance of ResponseGetTenantUserProfileResponse from a dict +response_get_tenant_user_profile_response_form_dict = response_get_tenant_user_profile_response.from_dict(response_get_tenant_user_profile_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/ResponsePasswordChangeEmailResponse.md b/docs/ResponsePasswordChangeEmailResponse.md new file mode 100644 index 00000000..1871cfe6 --- /dev/null +++ b/docs/ResponsePasswordChangeEmailResponse.md @@ -0,0 +1,30 @@ +# ResponsePasswordChangeEmailResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**PasswordChangeEmailResponse**](PasswordChangeEmailResponse.md) | | +**message** | **str** | | [optional] + +## Example + +```python +from onelens_backend_client.models.response_password_change_email_response import ResponsePasswordChangeEmailResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of ResponsePasswordChangeEmailResponse from a JSON string +response_password_change_email_response_instance = ResponsePasswordChangeEmailResponse.from_json(json) +# print the JSON string representation of the object +print(ResponsePasswordChangeEmailResponse.to_json()) + +# convert the object into a dict +response_password_change_email_response_dict = response_password_change_email_response_instance.to_dict() +# create an instance of ResponsePasswordChangeEmailResponse from a dict +response_password_change_email_response_form_dict = response_password_change_email_response.from_dict(response_password_change_email_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/Service.md b/docs/Service.md new file mode 100644 index 00000000..f2bb28b9 --- /dev/null +++ b/docs/Service.md @@ -0,0 +1,29 @@ +# Service + +Service AWS etc. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +## Example + +```python +from onelens_backend_client.models.service import Service + +# TODO update the JSON string below +json = "{}" +# create an instance of Service from a JSON string +service_instance = Service.from_json(json) +# print the JSON string representation of the object +print(Service.to_json()) + +# convert the object into a dict +service_dict = service_instance.to_dict() +# create an instance of Service from a dict +service_form_dict = service.from_dict(service_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/StorageLensConfig.md b/docs/StorageLensConfig.md new file mode 100644 index 00000000..1d073f6a --- /dev/null +++ b/docs/StorageLensConfig.md @@ -0,0 +1,30 @@ +# StorageLensConfig + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**region** | **str** | | [optional] + +## Example + +```python +from onelens_backend_client.models.storage_lens_config import StorageLensConfig + +# TODO update the JSON string below +json = "{}" +# create an instance of StorageLensConfig from a JSON string +storage_lens_config_instance = StorageLensConfig.from_json(json) +# print the JSON string representation of the object +print(StorageLensConfig.to_json()) + +# convert the object into a dict +storage_lens_config_dict = storage_lens_config_instance.to_dict() +# create an instance of StorageLensConfig from a dict +storage_lens_config_form_dict = storage_lens_config.from_dict(storage_lens_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/TenantPolicy.md b/docs/TenantPolicy.md index aa1edb02..11b4d2cc 100644 --- a/docs/TenantPolicy.md +++ b/docs/TenantPolicy.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **title** | **str** | The title of the policy template. | **alias** | **str** | The alias of the policy template. | **description** | **str** | The description of the policy template. | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | The list of services associated the policy template. | +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | The list of services associated the policy template. | **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | The execution type of the policy template. | **details** | [**PolicyTemplateDetailsOutput**](PolicyTemplateDetailsOutput.md) | The details of the policy template. | **description2** | **str** | The description2 of the policy template. | [optional] diff --git a/docs/TenantPolicyFilters.md b/docs/TenantPolicyFilters.md index f70b87ee..5c9cb3f9 100644 --- a/docs/TenantPolicyFilters.md +++ b/docs/TenantPolicyFilters.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **parent_ptp_ids** | **List[str]** | Filter by parent policy template pack id. | [optional] [default to []] **categories** | [**List[PolicyCategory]**](PolicyCategory.md) | Filter by type. | [optional] [default to []] **providers** | [**List[Provider]**](Provider.md) | Filter by provider. | [optional] [default to []] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | Filter by services. | [optional] [default to []] +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | Filter by services. | [optional] [default to []] **execution_types** | [**List[PolicyExecutionType]**](PolicyExecutionType.md) | Filter by execution type. | [optional] [default to []] ## Example diff --git a/docs/TenantUserServiceApi.md b/docs/TenantUserServiceApi.md index 0cbe0ccb..29d5b4aa 100644 --- a/docs/TenantUserServiceApi.md +++ b/docs/TenantUserServiceApi.md @@ -8,8 +8,10 @@ Method | Description [**create_tenant_user_from_ol_user_id**](TenantUserServiceApi.md#create_tenant_user_from_ol_user_id) | Creates a new user from onelens user id (ol_user_id). [**disable_tenant_user**](TenantUserServiceApi.md#disable_tenant_user) | Disables an existing tenant user. [**enable_tenant_user**](TenantUserServiceApi.md#enable_tenant_user) | Enables an existing tenant user. +[**enable_tenant_user_with_system**](TenantUserServiceApi.md#enable_tenant_user_with_system) | System Enables an existing tenant user. [**get_tenant_user_by_ol_user_id**](TenantUserServiceApi.md#get_tenant_user_by_ol_user_id) | Retrieves a tenant user by its unique onelens user id (ol_user_id). [**get_tenant_users**](TenantUserServiceApi.md#get_tenant_users) | Retrieves all tenant users. +[**send_email_to_user_for_password_change**](TenantUserServiceApi.md#send_email_to_user_for_password_change) | Sends a password change email to the user. [**update_tenant_user**](TenantUserServiceApi.md#update_tenant_user) | Updates an existing tenant user. [**update_tenant_user_details**](TenantUserServiceApi.md#update_tenant_user_details) | Updates tenant user details. @@ -255,6 +257,74 @@ with onelens_backend_client.ApiClient(configuration) as api_client: +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **enable_tenant_user_request** | [**EnableTenantUserRequest**](EnableTenantUserRequest.md)| | + +### Return type + +[**EnableTenantUserResponse**](EnableTenantUserResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enable_tenant_user_with_system** +> EnableTenantUserResponse enable_tenant_user_with_system(enable_tenant_user_request) + +System Enables an existing tenant user. + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.enable_tenant_user_request import EnableTenantUserRequest +from onelens_backend_client.models.enable_tenant_user_response import EnableTenantUserResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.TenantUserServiceApi(api_client) + enable_tenant_user_request = onelens_backend_client.EnableTenantUserRequest() # EnableTenantUserRequest | + + try: + # System Enables an existing tenant user. + api_response = api_instance.enable_tenant_user_with_system(enable_tenant_user_request) + print("The response of TenantUserServiceApi->enable_tenant_user_with_system:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantUserServiceApi->enable_tenant_user_with_system: %s\n" % e) +``` + + + ### Parameters @@ -420,6 +490,74 @@ No authorization required [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **send_email_to_user_for_password_change** +> PasswordChangeEmailResponse send_email_to_user_for_password_change(password_change_email_request) + +Sends a password change email to the user. + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.password_change_email_request import PasswordChangeEmailRequest +from onelens_backend_client.models.password_change_email_response import PasswordChangeEmailResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.TenantUserServiceApi(api_client) + password_change_email_request = onelens_backend_client.PasswordChangeEmailRequest() # PasswordChangeEmailRequest | + + try: + # Sends a password change email to the user. + api_response = api_instance.send_email_to_user_for_password_change(password_change_email_request) + print("The response of TenantUserServiceApi->send_email_to_user_for_password_change:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantUserServiceApi->send_email_to_user_for_password_change: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **password_change_email_request** | [**PasswordChangeEmailRequest**](PasswordChangeEmailRequest.md)| | + +### Return type + +[**PasswordChangeEmailResponse**](PasswordChangeEmailResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **update_tenant_user** > UpdateTenantUserResponse update_tenant_user(update_tenant_user_request) diff --git a/docs/TenantUsersApi.md b/docs/TenantUsersApi.md index 7495c898..b9430bc6 100644 --- a/docs/TenantUsersApi.md +++ b/docs/TenantUsersApi.md @@ -14,6 +14,10 @@ Method | Description [**get_all_tenant_users_with_filter_0**](TenantUsersApi.md#get_all_tenant_users_with_filter_0) | Get All Tenant Users With Filter [**get_tenant_user_by_ol_user_id**](TenantUsersApi.md#get_tenant_user_by_ol_user_id) | Get a user from the Tenant Database. [**get_tenant_user_by_ol_user_id_0**](TenantUsersApi.md#get_tenant_user_by_ol_user_id_0) | Get Tenant User By Ol User Id +[**get_tenant_user_profile**](TenantUsersApi.md#get_tenant_user_profile) | Get user profile from the Tenant Database. +[**get_tenant_user_profile_0**](TenantUsersApi.md#get_tenant_user_profile_0) | Get Tenant User Profile +[**send_email_to_user_for_password_change**](TenantUsersApi.md#send_email_to_user_for_password_change) | Send user password change email. +[**send_email_to_user_for_password_change_0**](TenantUsersApi.md#send_email_to_user_for_password_change_0) | Send Email To User For Password Change [**update_tenant_user**](TenantUsersApi.md#update_tenant_user) | Update a user in the Tenant Database. [**update_tenant_user_0**](TenantUsersApi.md#update_tenant_user_0) | Update Tenant User [**update_tenant_user_details**](TenantUsersApi.md#update_tenant_user_details) | Update a user details in the Tenant Database. @@ -714,6 +718,275 @@ No authorization required [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **get_tenant_user_profile** +> ResponseGetTenantUserProfileResponse get_tenant_user_profile(tenant_id) + +Get user profile from the Tenant Database. + +Get user profile in the Tenant Database. + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.response_get_tenant_user_profile_response import ResponseGetTenantUserProfileResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.TenantUsersApi(api_client) + tenant_id = 'tenant_id_example' # str | + + try: + # Get user profile from the Tenant Database. + api_response = api_instance.get_tenant_user_profile(tenant_id) + print("The response of TenantUsersApi->get_tenant_user_profile:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantUsersApi->get_tenant_user_profile: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_id** | **str**| | + +### Return type + +[**ResponseGetTenantUserProfileResponse**](ResponseGetTenantUserProfileResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **get_tenant_user_profile_0** +> ResponseGetTenantUserProfileResponse get_tenant_user_profile_0() + +Get Tenant User Profile + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.response_get_tenant_user_profile_response import ResponseGetTenantUserProfileResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.TenantUsersApi(api_client) + + try: + # Get Tenant User Profile + api_response = api_instance.get_tenant_user_profile_0() + print("The response of TenantUsersApi->get_tenant_user_profile_0:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantUsersApi->get_tenant_user_profile_0: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**ResponseGetTenantUserProfileResponse**](ResponseGetTenantUserProfileResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **send_email_to_user_for_password_change** +> ResponsePasswordChangeEmailResponse send_email_to_user_for_password_change(tenant_id, ol_user_id) + +Send user password change email. + +Send user password change email. + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.response_password_change_email_response import ResponsePasswordChangeEmailResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.TenantUsersApi(api_client) + tenant_id = 'tenant_id_example' # str | + ol_user_id = 'ol_user_id_example' # str | + + try: + # Send user password change email. + api_response = api_instance.send_email_to_user_for_password_change(tenant_id, ol_user_id) + print("The response of TenantUsersApi->send_email_to_user_for_password_change:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantUsersApi->send_email_to_user_for_password_change: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_id** | **str**| | + **ol_user_id** | **str**| | + +### Return type + +[**ResponsePasswordChangeEmailResponse**](ResponsePasswordChangeEmailResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **send_email_to_user_for_password_change_0** +> ResponsePasswordChangeEmailResponse send_email_to_user_for_password_change_0(ol_user_id) + +Send Email To User For Password Change + +### Example + + +```python +import onelens_backend_client +from onelens_backend_client.models.response_password_change_email_response import ResponsePasswordChangeEmailResponse +from onelens_backend_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = onelens_backend_client.Configuration( + host = "http://localhost" +) + + +# Enter a context with an instance of the API client +with onelens_backend_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = onelens_backend_client.TenantUsersApi(api_client) + ol_user_id = 'ol_user_id_example' # str | + + try: + # Send Email To User For Password Change + api_response = api_instance.send_email_to_user_for_password_change_0(ol_user_id) + print("The response of TenantUsersApi->send_email_to_user_for_password_change_0:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantUsersApi->send_email_to_user_for_password_change_0: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ol_user_id** | **str**| | + +### Return type + +[**ResponsePasswordChangeEmailResponse**](ResponsePasswordChangeEmailResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **update_tenant_user** > ResponseUpdateTenantUserResponse update_tenant_user(tenant_id, ol_user_id, tenant_user_update_fields_mixin) diff --git a/docs/TenantVerifyRequestWithUser.md b/docs/TenantVerifyRequestWithUser.md index 7551c575..c6ee7f29 100644 --- a/docs/TenantVerifyRequestWithUser.md +++ b/docs/TenantVerifyRequestWithUser.md @@ -8,6 +8,7 @@ Name | Type | Description | Notes **role_name** | **str** | Role name of the tenant | **tenant_id** | **str** | Tenant ID | **tenant_provider_id** | **str** | Tenant Provider ID | +**storage_lens_config** | [**StorageLensConfig**](StorageLensConfig.md) | | [optional] **user_id** | **str** | List of users | ## Example diff --git a/docs/UpdateActionTypeRequest.md b/docs/UpdateActionTypeRequest.md new file mode 100644 index 00000000..c4ad7550 --- /dev/null +++ b/docs/UpdateActionTypeRequest.md @@ -0,0 +1,33 @@ +# UpdateActionTypeRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**service** | [**Service**](Service.md) | | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**id** | **int** | Action Type ID | + +## Example + +```python +from onelens_backend_client.models.update_action_type_request import UpdateActionTypeRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UpdateActionTypeRequest from a JSON string +update_action_type_request_instance = UpdateActionTypeRequest.from_json(json) +# print the JSON string representation of the object +print(UpdateActionTypeRequest.to_json()) + +# convert the object into a dict +update_action_type_request_dict = update_action_type_request_instance.to_dict() +# create an instance of UpdateActionTypeRequest from a dict +update_action_type_request_form_dict = update_action_type_request.from_dict(update_action_type_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UpdateActionTypeResponse.md b/docs/UpdateActionTypeResponse.md new file mode 100644 index 00000000..3c978e3e --- /dev/null +++ b/docs/UpdateActionTypeResponse.md @@ -0,0 +1,33 @@ +# UpdateActionTypeResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**service** | [**Service**](Service.md) | | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**id** | **int** | Action Type ID | + +## Example + +```python +from onelens_backend_client.models.update_action_type_response import UpdateActionTypeResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of UpdateActionTypeResponse from a JSON string +update_action_type_response_instance = UpdateActionTypeResponse.from_json(json) +# print the JSON string representation of the object +print(UpdateActionTypeResponse.to_json()) + +# convert the object into a dict +update_action_type_response_dict = update_action_type_response_instance.to_dict() +# create an instance of UpdateActionTypeResponse from a dict +update_action_type_response_form_dict = update_action_type_response.from_dict(update_action_type_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/UpdatePolicyTemplateRequest.md b/docs/UpdatePolicyTemplateRequest.md index 98fbe17b..1fe9e2bf 100644 --- a/docs/UpdatePolicyTemplateRequest.md +++ b/docs/UpdatePolicyTemplateRequest.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes **force_update** | **bool** | Force update (TRUE/FALSE), default: FALSE | [optional] [default to False] **title** | **str** | | [optional] **description** | **str** | | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | | [optional] +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | | [optional] **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | | [optional] **details** | [**PolicyTemplateDetailsInput**](PolicyTemplateDetailsInput.md) | | [optional] **description2** | **str** | | [optional] diff --git a/docs/UpdatePolicyTemplateResponse.md b/docs/UpdatePolicyTemplateResponse.md index fb87a602..c9526751 100644 --- a/docs/UpdatePolicyTemplateResponse.md +++ b/docs/UpdatePolicyTemplateResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **title** | **str** | The title of the policy template. | **alias** | **str** | The alias of the policy template. | **description** | **str** | The description of the policy template. | [optional] -**services** | [**List[CreatePolicyTemplateRequestServicesInner]**](CreatePolicyTemplateRequestServicesInner.md) | The list of services associated the policy template. | +**services** | [**List[ActionTypeFiltersServicesInner]**](ActionTypeFiltersServicesInner.md) | The list of services associated the policy template. | **execution_type** | [**PolicyExecutionType**](PolicyExecutionType.md) | The execution type of the policy template. | **details** | [**PolicyTemplateDetailsOutput**](PolicyTemplateDetailsOutput.md) | The details of the policy template. | **description2** | **str** | The description2 of the policy template. | [optional] diff --git a/docs/UpdateRecommendationUnitRequest.md b/docs/UpdateRecommendationUnitRequest.md new file mode 100644 index 00000000..2ee70fca --- /dev/null +++ b/docs/UpdateRecommendationUnitRequest.md @@ -0,0 +1,37 @@ +# UpdateRecommendationUnitRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | Recommendation Config ID | +**service** | **str** | Service AWS etc. | +**action_type_id** | **int** | | [optional] +**priority** | **int** | Priority | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**effort** | [**Effort**](Effort.md) | Effort | +**query_details** | [**RecommendationQueryDetails**](RecommendationQueryDetails.md) | | + +## Example + +```python +from onelens_backend_client.models.update_recommendation_unit_request import UpdateRecommendationUnitRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UpdateRecommendationUnitRequest from a JSON string +update_recommendation_unit_request_instance = UpdateRecommendationUnitRequest.from_json(json) +# print the JSON string representation of the object +print(UpdateRecommendationUnitRequest.to_json()) + +# convert the object into a dict +update_recommendation_unit_request_dict = update_recommendation_unit_request_instance.to_dict() +# create an instance of UpdateRecommendationUnitRequest from a dict +update_recommendation_unit_request_form_dict = update_recommendation_unit_request.from_dict(update_recommendation_unit_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UpdateRecommendationUnitResponse.md b/docs/UpdateRecommendationUnitResponse.md new file mode 100644 index 00000000..8dd2cb6b --- /dev/null +++ b/docs/UpdateRecommendationUnitResponse.md @@ -0,0 +1,37 @@ +# UpdateRecommendationUnitResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | Recommendation Config ID | +**service** | **str** | Service AWS etc. | +**action_type_id** | **int** | | [optional] +**priority** | **int** | Priority | +**title** | **str** | Title | +**subtitle** | **str** | | [optional] +**description** | **str** | Description | +**effort** | [**Effort**](Effort.md) | Effort | +**query_details** | [**RecommendationQueryDetails**](RecommendationQueryDetails.md) | | + +## Example + +```python +from onelens_backend_client.models.update_recommendation_unit_response import UpdateRecommendationUnitResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of UpdateRecommendationUnitResponse from a JSON string +update_recommendation_unit_response_instance = UpdateRecommendationUnitResponse.from_json(json) +# print the JSON string representation of the object +print(UpdateRecommendationUnitResponse.to_json()) + +# convert the object into a dict +update_recommendation_unit_response_dict = update_recommendation_unit_response_instance.to_dict() +# create an instance of UpdateRecommendationUnitResponse from a dict +update_recommendation_unit_response_form_dict = update_recommendation_unit_response.from_dict(update_recommendation_unit_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/onelens_backend_client/__init__.py b/onelens_backend_client/__init__.py index 028b4c28..f7cd5841 100644 --- a/onelens_backend_client/__init__.py +++ b/onelens_backend_client/__init__.py @@ -33,6 +33,7 @@ from onelens_backend_client.api.policy_template_service_api import PolicyTemplateServiceApi from onelens_backend_client.api.recommendation_engine_service_api import RecommendationEngineServiceApi from onelens_backend_client.api.recommendation_service_api import RecommendationServiceApi +from onelens_backend_client.api.recommendation_unit_service_api import RecommendationUnitServiceApi from onelens_backend_client.api.resource_catalog_api import ResourceCatalogApi from onelens_backend_client.api.resource_catalog_service_api import ResourceCatalogServiceApi from onelens_backend_client.api.resource_mapping_service_api import ResourceMappingServiceApi @@ -69,6 +70,9 @@ from onelens_backend_client.exceptions import ApiException # import models into sdk package +from onelens_backend_client.models.action_type import ActionType +from onelens_backend_client.models.action_type_filters import ActionTypeFilters +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.activate_policy_template_request import ActivatePolicyTemplateRequest from onelens_backend_client.models.add_tenant_policy_exclusions_api_request import AddTenantPolicyExclusionsAPIRequest from onelens_backend_client.models.add_tenant_policy_exclusions_request import AddTenantPolicyExclusionsRequest @@ -90,6 +94,8 @@ from onelens_backend_client.models.bulk_update_tenant_tickets_response import BulkUpdateTenantTicketsResponse from onelens_backend_client.models.city import City from onelens_backend_client.models.country import Country +from onelens_backend_client.models.create_action_type_request import CreateActionTypeRequest +from onelens_backend_client.models.create_action_type_response import CreateActionTypeResponse from onelens_backend_client.models.create_auth0_and_onelens_user_response import CreateAuth0AndOnelensUserResponse from onelens_backend_client.models.create_auth0_user_request import CreateAuth0UserRequest from onelens_backend_client.models.create_default_hierarchy_request import CreateDefaultHierarchyRequest @@ -104,8 +110,9 @@ from onelens_backend_client.models.create_policy_template_pack_request import CreatePolicyTemplatePackRequest from onelens_backend_client.models.create_policy_template_pack_response import CreatePolicyTemplatePackResponse from onelens_backend_client.models.create_policy_template_request import CreatePolicyTemplateRequest -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner from onelens_backend_client.models.create_policy_template_response import CreatePolicyTemplateResponse +from onelens_backend_client.models.create_recommendation_unit_request import CreateRecommendationUnitRequest +from onelens_backend_client.models.create_recommendation_unit_response import CreateRecommendationUnitResponse from onelens_backend_client.models.create_tenant_provider_request import CreateTenantProviderRequest from onelens_backend_client.models.create_tenant_provider_response import CreateTenantProviderResponse from onelens_backend_client.models.create_tenant_request_with_user import CreateTenantRequestWithUser @@ -130,7 +137,6 @@ from onelens_backend_client.models.deactivate_policy_template_request import DeactivatePolicyTemplateRequest from onelens_backend_client.models.delete_hierarchy_node_request import DeleteHierarchyNodeRequest from onelens_backend_client.models.deprecate_policy_template_request import DeprecatePolicyTemplateRequest -from onelens_backend_client.models.derived_variable import DerivedVariable from onelens_backend_client.models.details import Details from onelens_backend_client.models.details1 import Details1 from onelens_backend_client.models.details2 import Details2 @@ -156,6 +162,8 @@ from onelens_backend_client.models.features import Features from onelens_backend_client.models.first_name import FirstName from onelens_backend_client.models.gcp_service import GcpService +from onelens_backend_client.models.get_action_type_request import GetActionTypeRequest +from onelens_backend_client.models.get_action_type_response import GetActionTypeResponse from onelens_backend_client.models.get_all_policy_violations_api_request import GetAllPolicyViolationsAPIRequest from onelens_backend_client.models.get_all_policy_violations_request import GetAllPolicyViolationsRequest from onelens_backend_client.models.get_all_policy_violations_response import GetAllPolicyViolationsResponse @@ -200,6 +208,7 @@ from onelens_backend_client.models.get_recommendation_ticket_response import GetRecommendationTicketResponse from onelens_backend_client.models.get_recommendation_unit_by_id_request import GetRecommendationUnitByIdRequest from onelens_backend_client.models.get_recommendation_unit_by_id_response import GetRecommendationUnitByIdResponse +from onelens_backend_client.models.get_recommendation_unit_request import GetRecommendationUnitRequest from onelens_backend_client.models.get_recommendation_units_request import GetRecommendationUnitsRequest from onelens_backend_client.models.get_recommendation_units_response import GetRecommendationUnitsResponse from onelens_backend_client.models.get_resource_hierarchy_mapping_by_ol_id_request import GetResourceHierarchyMappingByOlIdRequest @@ -235,6 +244,7 @@ from onelens_backend_client.models.get_tenant_tickets_response import GetTenantTicketsResponse from onelens_backend_client.models.get_tenant_user_by_id_request import GetTenantUserByIDRequest from onelens_backend_client.models.get_tenant_user_by_id_response import GetTenantUserByIDResponse +from onelens_backend_client.models.get_tenant_user_profile_response import GetTenantUserProfileResponse from onelens_backend_client.models.get_tenant_users_with_filter_api_request import GetTenantUsersWithFilterAPIRequest from onelens_backend_client.models.get_tenant_users_with_filter_request import GetTenantUsersWithFilterRequest from onelens_backend_client.models.get_tenant_users_with_filter_response import GetTenantUsersWithFilterResponse @@ -289,6 +299,8 @@ from onelens_backend_client.models.override_tenant_policy_exclusions_response import OverrideTenantPolicyExclusionsResponse from onelens_backend_client.models.pagination_fields import PaginationFields from onelens_backend_client.models.pagination_params import PaginationParams +from onelens_backend_client.models.password_change_email_request import PasswordChangeEmailRequest +from onelens_backend_client.models.password_change_email_response import PasswordChangeEmailResponse from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_recommendation_params import PolicyRecommendationParams @@ -313,7 +325,7 @@ from onelens_backend_client.models.provider_config_input import ProviderConfigInput from onelens_backend_client.models.provider_config_output import ProviderConfigOutput from onelens_backend_client.models.publish_custom_hierarchy_request import PublishCustomHierarchyRequest -from onelens_backend_client.models.query_details import QueryDetails +from onelens_backend_client.models.query_details_derived_variables import QueryDetailsDerivedVariables from onelens_backend_client.models.query_filters import QueryFilters from onelens_backend_client.models.query_order import QueryOrder from onelens_backend_client.models.recommendation_engine import RecommendationEngine @@ -321,11 +333,14 @@ from onelens_backend_client.models.recommendation_engine_request import RecommendationEngineRequest from onelens_backend_client.models.recommendation_engine_response import RecommendationEngineResponse from onelens_backend_client.models.recommendation_params import RecommendationParams +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails from onelens_backend_client.models.recommendation_ticket import RecommendationTicket from onelens_backend_client.models.recommendation_ticket_api_request_input import RecommendationTicketAPIRequestInput from onelens_backend_client.models.recommendation_ticket_api_request_output import RecommendationTicketAPIRequestOutput from onelens_backend_client.models.recommendation_ticket_request import RecommendationTicketRequest from onelens_backend_client.models.recommendation_ticket_response import RecommendationTicketResponse +from onelens_backend_client.models.recommendation_unit import RecommendationUnit +from onelens_backend_client.models.recommendation_unit_filters import RecommendationUnitFilters from onelens_backend_client.models.relationship_config_item import RelationshipConfigItem from onelens_backend_client.models.resource_catalog import ResourceCatalog from onelens_backend_client.models.resource_catalog_request import ResourceCatalogRequest @@ -376,11 +391,13 @@ from onelens_backend_client.models.response_get_tenant_providers_response import ResponseGetTenantProvidersResponse from onelens_backend_client.models.response_get_tenant_tickets_response import ResponseGetTenantTicketsResponse from onelens_backend_client.models.response_get_tenant_user_by_id_response import ResponseGetTenantUserByIDResponse +from onelens_backend_client.models.response_get_tenant_user_profile_response import ResponseGetTenantUserProfileResponse from onelens_backend_client.models.response_get_tenant_users_with_filter_response import ResponseGetTenantUsersWithFilterResponse from onelens_backend_client.models.response_get_tenants_response import ResponseGetTenantsResponse from onelens_backend_client.models.response_get_ticket_by_id_policy_details_response import ResponseGetTicketByIdPolicyDetailsResponse from onelens_backend_client.models.response_override_tenant_anomaly_config_response import ResponseOverrideTenantAnomalyConfigResponse from onelens_backend_client.models.response_override_tenant_policy_exclusions_response import ResponseOverrideTenantPolicyExclusionsResponse +from onelens_backend_client.models.response_password_change_email_response import ResponsePasswordChangeEmailResponse from onelens_backend_client.models.response_recommendation_engine_response import ResponseRecommendationEngineResponse from onelens_backend_client.models.response_recommendation_ticket_response import ResponseRecommendationTicketResponse from onelens_backend_client.models.response_resource_catalog_response import ResponseResourceCatalogResponse @@ -395,11 +412,11 @@ from onelens_backend_client.models.response_update_tenant_user_details_response import ResponseUpdateTenantUserDetailsResponse from onelens_backend_client.models.response_update_tenant_user_response import ResponseUpdateTenantUserResponse from onelens_backend_client.models.rule_type import RuleType +from onelens_backend_client.models.service import Service from onelens_backend_client.models.service_catalog import ServiceCatalog from onelens_backend_client.models.service_catalog_request import ServiceCatalogRequest from onelens_backend_client.models.service_catalog_request_find import ServiceCatalogRequestFind from onelens_backend_client.models.service_catalog_response import ServiceCatalogResponse -from onelens_backend_client.models.service_config import ServiceConfig from onelens_backend_client.models.set_tenant_status_request import SetTenantStatusRequest from onelens_backend_client.models.sort_criteria import SortCriteria from onelens_backend_client.models.sources import Sources @@ -407,6 +424,7 @@ from onelens_backend_client.models.status import Status from onelens_backend_client.models.status1 import Status1 from onelens_backend_client.models.statuses import Statuses +from onelens_backend_client.models.storage_lens_config import StorageLensConfig from onelens_backend_client.models.tenant import Tenant from onelens_backend_client.models.tenant_anomaly_setting_filters import TenantAnomalySettingFilters from onelens_backend_client.models.tenant_anomaly_settings import TenantAnomalySettings @@ -445,6 +463,8 @@ from onelens_backend_client.models.time_dimension_output import TimeDimensionOutput from onelens_backend_client.models.time_dimension_output_compare_date_range_inner import TimeDimensionOutputCompareDateRangeInner from onelens_backend_client.models.timezone import Timezone +from onelens_backend_client.models.update_action_type_request import UpdateActionTypeRequest +from onelens_backend_client.models.update_action_type_response import UpdateActionTypeResponse from onelens_backend_client.models.update_hierarchy_node_api_request import UpdateHierarchyNodeAPIRequest from onelens_backend_client.models.update_hierarchy_node_request import UpdateHierarchyNodeRequest from onelens_backend_client.models.update_hierarchy_node_response import UpdateHierarchyNodeResponse @@ -452,6 +472,8 @@ from onelens_backend_client.models.update_organization_response import UpdateOrganizationResponse from onelens_backend_client.models.update_policy_template_request import UpdatePolicyTemplateRequest from onelens_backend_client.models.update_policy_template_response import UpdatePolicyTemplateResponse +from onelens_backend_client.models.update_recommendation_unit_request import UpdateRecommendationUnitRequest +from onelens_backend_client.models.update_recommendation_unit_response import UpdateRecommendationUnitResponse from onelens_backend_client.models.update_tenant_policy_setting_last_run_at_request import UpdateTenantPolicySettingLastRunAtRequest from onelens_backend_client.models.update_tenant_request import UpdateTenantRequest from onelens_backend_client.models.update_tenant_response import UpdateTenantResponse diff --git a/onelens_backend_client/api/__init__.py b/onelens_backend_client/api/__init__.py index 690643fb..3fb307ac 100644 --- a/onelens_backend_client/api/__init__.py +++ b/onelens_backend_client/api/__init__.py @@ -17,6 +17,7 @@ from onelens_backend_client.api.policy_template_service_api import PolicyTemplateServiceApi from onelens_backend_client.api.recommendation_engine_service_api import RecommendationEngineServiceApi from onelens_backend_client.api.recommendation_service_api import RecommendationServiceApi +from onelens_backend_client.api.recommendation_unit_service_api import RecommendationUnitServiceApi from onelens_backend_client.api.resource_catalog_api import ResourceCatalogApi from onelens_backend_client.api.resource_catalog_service_api import ResourceCatalogServiceApi from onelens_backend_client.api.resource_mapping_service_api import ResourceMappingServiceApi diff --git a/onelens_backend_client/api/recommendation_engine_service_api.py b/onelens_backend_client/api/recommendation_engine_service_api.py index 67753a1d..aafc001f 100644 --- a/onelens_backend_client/api/recommendation_engine_service_api.py +++ b/onelens_backend_client/api/recommendation_engine_service_api.py @@ -16,12 +16,14 @@ from typing import Any, Dict, List, Optional, Tuple, Union from typing_extensions import Annotated -from onelens_backend_client.models.get_recommendation_unit_by_id_request import GetRecommendationUnitByIdRequest -from onelens_backend_client.models.get_recommendation_unit_by_id_response import GetRecommendationUnitByIdResponse -from onelens_backend_client.models.get_recommendation_units_request import GetRecommendationUnitsRequest -from onelens_backend_client.models.get_recommendation_units_response import GetRecommendationUnitsResponse +from onelens_backend_client.models.create_action_type_request import CreateActionTypeRequest +from onelens_backend_client.models.create_action_type_response import CreateActionTypeResponse +from onelens_backend_client.models.get_action_type_request import GetActionTypeRequest +from onelens_backend_client.models.get_action_type_response import GetActionTypeResponse from onelens_backend_client.models.recommendation_engine_request import RecommendationEngineRequest from onelens_backend_client.models.recommendation_engine_response import RecommendationEngineResponse +from onelens_backend_client.models.update_action_type_request import UpdateActionTypeRequest +from onelens_backend_client.models.update_action_type_response import UpdateActionTypeResponse from onelens_backend_client.api_client import ApiClient, RequestSerialized from onelens_backend_client.api_response import ApiResponse @@ -42,9 +44,9 @@ def __init__(self, api_client=None) -> None: @validate_call - def get_recommendation_unit_by_id( + def create_action_type( self, - get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest, + create_action_type_request: CreateActionTypeRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -57,12 +59,12 @@ def get_recommendation_unit_by_id( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetRecommendationUnitByIdResponse: - """Retrieves all Tenants with filters. + ) -> CreateActionTypeResponse: + """Create Action Type - :param get_recommendation_unit_by_id_request: (required) - :type get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest + :param create_action_type_request: (required) + :type create_action_type_request: CreateActionTypeRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -85,8 +87,8 @@ def get_recommendation_unit_by_id( :return: Returns the result object. """ # noqa: E501 - _param = self._get_recommendation_unit_by_id_serialize( - get_recommendation_unit_by_id_request=get_recommendation_unit_by_id_request, + _param = self._create_action_type_serialize( + create_action_type_request=create_action_type_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -94,7 +96,7 @@ def get_recommendation_unit_by_id( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetRecommendationUnitByIdResponse", + '200': "CreateActionTypeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -109,9 +111,9 @@ def get_recommendation_unit_by_id( @validate_call - def get_recommendation_unit_by_id_with_http_info( + def create_action_type_with_http_info( self, - get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest, + create_action_type_request: CreateActionTypeRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -124,12 +126,12 @@ def get_recommendation_unit_by_id_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetRecommendationUnitByIdResponse]: - """Retrieves all Tenants with filters. + ) -> ApiResponse[CreateActionTypeResponse]: + """Create Action Type - :param get_recommendation_unit_by_id_request: (required) - :type get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest + :param create_action_type_request: (required) + :type create_action_type_request: CreateActionTypeRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -152,8 +154,8 @@ def get_recommendation_unit_by_id_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_recommendation_unit_by_id_serialize( - get_recommendation_unit_by_id_request=get_recommendation_unit_by_id_request, + _param = self._create_action_type_serialize( + create_action_type_request=create_action_type_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -161,7 +163,7 @@ def get_recommendation_unit_by_id_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetRecommendationUnitByIdResponse", + '200': "CreateActionTypeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -176,9 +178,9 @@ def get_recommendation_unit_by_id_with_http_info( @validate_call - def get_recommendation_unit_by_id_without_preload_content( + def create_action_type_without_preload_content( self, - get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest, + create_action_type_request: CreateActionTypeRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -192,11 +194,11 @@ def get_recommendation_unit_by_id_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Retrieves all Tenants with filters. + """Create Action Type - :param get_recommendation_unit_by_id_request: (required) - :type get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest + :param create_action_type_request: (required) + :type create_action_type_request: CreateActionTypeRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -219,8 +221,8 @@ def get_recommendation_unit_by_id_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._get_recommendation_unit_by_id_serialize( - get_recommendation_unit_by_id_request=get_recommendation_unit_by_id_request, + _param = self._create_action_type_serialize( + create_action_type_request=create_action_type_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -228,7 +230,7 @@ def get_recommendation_unit_by_id_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetRecommendationUnitByIdResponse", + '200': "CreateActionTypeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -238,9 +240,9 @@ def get_recommendation_unit_by_id_without_preload_content( return response_data.response - def _get_recommendation_unit_by_id_serialize( + def _create_action_type_serialize( self, - get_recommendation_unit_by_id_request, + create_action_type_request, _request_auth, _content_type, _headers, @@ -264,8 +266,8 @@ def _get_recommendation_unit_by_id_serialize( # process the header parameters # process the form parameters # process the body parameter - if get_recommendation_unit_by_id_request is not None: - _body_params = get_recommendation_unit_by_id_request + if create_action_type_request is not None: + _body_params = create_action_type_request # set the HTTP header `Accept` @@ -295,7 +297,7 @@ def _get_recommendation_unit_by_id_serialize( return self.api_client.param_serialize( method='POST', - resource_path='/rpc/recommendation_engine_service/get_recommendation_unit_by_id', + resource_path='/rpc/recommendation_engine_service/create_action_type', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -312,9 +314,9 @@ def _get_recommendation_unit_by_id_serialize( @validate_call - def get_recommendation_units( + def get_action_types( self, - get_recommendation_units_request: GetRecommendationUnitsRequest, + get_action_type_request: GetActionTypeRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -327,12 +329,12 @@ def get_recommendation_units( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetRecommendationUnitsResponse: - """Retrieves all recommendation units by filter + ) -> GetActionTypeResponse: + """Get Action Types - :param get_recommendation_units_request: (required) - :type get_recommendation_units_request: GetRecommendationUnitsRequest + :param get_action_type_request: (required) + :type get_action_type_request: GetActionTypeRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -355,8 +357,8 @@ def get_recommendation_units( :return: Returns the result object. """ # noqa: E501 - _param = self._get_recommendation_units_serialize( - get_recommendation_units_request=get_recommendation_units_request, + _param = self._get_action_types_serialize( + get_action_type_request=get_action_type_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -364,7 +366,7 @@ def get_recommendation_units( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetRecommendationUnitsResponse", + '200': "GetActionTypeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -379,9 +381,9 @@ def get_recommendation_units( @validate_call - def get_recommendation_units_with_http_info( + def get_action_types_with_http_info( self, - get_recommendation_units_request: GetRecommendationUnitsRequest, + get_action_type_request: GetActionTypeRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -394,12 +396,12 @@ def get_recommendation_units_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetRecommendationUnitsResponse]: - """Retrieves all recommendation units by filter + ) -> ApiResponse[GetActionTypeResponse]: + """Get Action Types - :param get_recommendation_units_request: (required) - :type get_recommendation_units_request: GetRecommendationUnitsRequest + :param get_action_type_request: (required) + :type get_action_type_request: GetActionTypeRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -422,8 +424,8 @@ def get_recommendation_units_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_recommendation_units_serialize( - get_recommendation_units_request=get_recommendation_units_request, + _param = self._get_action_types_serialize( + get_action_type_request=get_action_type_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -431,7 +433,7 @@ def get_recommendation_units_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetRecommendationUnitsResponse", + '200': "GetActionTypeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -446,9 +448,9 @@ def get_recommendation_units_with_http_info( @validate_call - def get_recommendation_units_without_preload_content( + def get_action_types_without_preload_content( self, - get_recommendation_units_request: GetRecommendationUnitsRequest, + get_action_type_request: GetActionTypeRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -462,11 +464,11 @@ def get_recommendation_units_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Retrieves all recommendation units by filter + """Get Action Types - :param get_recommendation_units_request: (required) - :type get_recommendation_units_request: GetRecommendationUnitsRequest + :param get_action_type_request: (required) + :type get_action_type_request: GetActionTypeRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -489,8 +491,8 @@ def get_recommendation_units_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._get_recommendation_units_serialize( - get_recommendation_units_request=get_recommendation_units_request, + _param = self._get_action_types_serialize( + get_action_type_request=get_action_type_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -498,7 +500,7 @@ def get_recommendation_units_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetRecommendationUnitsResponse", + '200': "GetActionTypeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -508,9 +510,9 @@ def get_recommendation_units_without_preload_content( return response_data.response - def _get_recommendation_units_serialize( + def _get_action_types_serialize( self, - get_recommendation_units_request, + get_action_type_request, _request_auth, _content_type, _headers, @@ -534,8 +536,8 @@ def _get_recommendation_units_serialize( # process the header parameters # process the form parameters # process the body parameter - if get_recommendation_units_request is not None: - _body_params = get_recommendation_units_request + if get_action_type_request is not None: + _body_params = get_action_type_request # set the HTTP header `Accept` @@ -565,7 +567,7 @@ def _get_recommendation_units_serialize( return self.api_client.param_serialize( method='POST', - resource_path='/rpc/recommendation_engine_service/get_recommendation_units', + resource_path='/rpc/recommendation_engine_service/get_action_types', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -849,3 +851,273 @@ def _get_recommendations_serialize( ) + + + @validate_call + def update_action_type( + self, + update_action_type_request: UpdateActionTypeRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UpdateActionTypeResponse: + """Update Action Type + + + :param update_action_type_request: (required) + :type update_action_type_request: UpdateActionTypeRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._update_action_type_serialize( + update_action_type_request=update_action_type_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UpdateActionTypeResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def update_action_type_with_http_info( + self, + update_action_type_request: UpdateActionTypeRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UpdateActionTypeResponse]: + """Update Action Type + + + :param update_action_type_request: (required) + :type update_action_type_request: UpdateActionTypeRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._update_action_type_serialize( + update_action_type_request=update_action_type_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UpdateActionTypeResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def update_action_type_without_preload_content( + self, + update_action_type_request: UpdateActionTypeRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Update Action Type + + + :param update_action_type_request: (required) + :type update_action_type_request: UpdateActionTypeRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._update_action_type_serialize( + update_action_type_request=update_action_type_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UpdateActionTypeResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _update_action_type_serialize( + self, + update_action_type_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[str, Union[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 update_action_type_request is not None: + _body_params = update_action_type_request + + + # set the HTTP header `Accept` + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_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='/rpc/recommendation_engine_service/update_action_type', + path_params=_path_params, + query_params=_query_params, + header_params=_header_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/onelens_backend_client/api/recommendation_unit_service_api.py b/onelens_backend_client/api/recommendation_unit_service_api.py new file mode 100644 index 00000000..943cda62 --- /dev/null +++ b/onelens_backend_client/api/recommendation_unit_service_api.py @@ -0,0 +1,1123 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + 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 onelens_backend_client.models.create_recommendation_unit_request import CreateRecommendationUnitRequest +from onelens_backend_client.models.create_recommendation_unit_response import CreateRecommendationUnitResponse +from onelens_backend_client.models.get_recommendation_unit_by_id_request import GetRecommendationUnitByIdRequest +from onelens_backend_client.models.get_recommendation_unit_by_id_response import GetRecommendationUnitByIdResponse +from onelens_backend_client.models.get_recommendation_unit_request import GetRecommendationUnitRequest +from onelens_backend_client.models.get_recommendation_units_response import GetRecommendationUnitsResponse +from onelens_backend_client.models.update_recommendation_unit_request import UpdateRecommendationUnitRequest +from onelens_backend_client.models.update_recommendation_unit_response import UpdateRecommendationUnitResponse + +from onelens_backend_client.api_client import ApiClient, RequestSerialized +from onelens_backend_client.api_response import ApiResponse +from onelens_backend_client.rest import RESTResponseType + + +class RecommendationUnitServiceApi: + """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 create_recommendation_unit( + self, + create_recommendation_unit_request: CreateRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CreateRecommendationUnitResponse: + """Create recommendation unit + + + :param create_recommendation_unit_request: (required) + :type create_recommendation_unit_request: CreateRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._create_recommendation_unit_serialize( + create_recommendation_unit_request=create_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CreateRecommendationUnitResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def create_recommendation_unit_with_http_info( + self, + create_recommendation_unit_request: CreateRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CreateRecommendationUnitResponse]: + """Create recommendation unit + + + :param create_recommendation_unit_request: (required) + :type create_recommendation_unit_request: CreateRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._create_recommendation_unit_serialize( + create_recommendation_unit_request=create_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CreateRecommendationUnitResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def create_recommendation_unit_without_preload_content( + self, + create_recommendation_unit_request: CreateRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Create recommendation unit + + + :param create_recommendation_unit_request: (required) + :type create_recommendation_unit_request: CreateRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._create_recommendation_unit_serialize( + create_recommendation_unit_request=create_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CreateRecommendationUnitResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _create_recommendation_unit_serialize( + self, + create_recommendation_unit_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[str, Union[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 create_recommendation_unit_request is not None: + _body_params = create_recommendation_unit_request + + + # set the HTTP header `Accept` + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_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='/rpc/recommendation_unit_service/create_recommendation_unit', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def get_recommendation_unit_by_id( + self, + get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GetRecommendationUnitByIdResponse: + """Retrieves Recommendation unit ID. + + + :param get_recommendation_unit_by_id_request: (required) + :type get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_recommendation_unit_by_id_serialize( + get_recommendation_unit_by_id_request=get_recommendation_unit_by_id_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetRecommendationUnitByIdResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def get_recommendation_unit_by_id_with_http_info( + self, + get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GetRecommendationUnitByIdResponse]: + """Retrieves Recommendation unit ID. + + + :param get_recommendation_unit_by_id_request: (required) + :type get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_recommendation_unit_by_id_serialize( + get_recommendation_unit_by_id_request=get_recommendation_unit_by_id_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetRecommendationUnitByIdResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def get_recommendation_unit_by_id_without_preload_content( + self, + get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Retrieves Recommendation unit ID. + + + :param get_recommendation_unit_by_id_request: (required) + :type get_recommendation_unit_by_id_request: GetRecommendationUnitByIdRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_recommendation_unit_by_id_serialize( + get_recommendation_unit_by_id_request=get_recommendation_unit_by_id_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetRecommendationUnitByIdResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _get_recommendation_unit_by_id_serialize( + self, + get_recommendation_unit_by_id_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[str, Union[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 get_recommendation_unit_by_id_request is not None: + _body_params = get_recommendation_unit_by_id_request + + + # set the HTTP header `Accept` + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_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='/rpc/recommendation_unit_service/get_recommendation_unit_by_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 get_recommendation_units( + self, + get_recommendation_unit_request: GetRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GetRecommendationUnitsResponse: + """Retrieves all recommendation units with filters + + + :param get_recommendation_unit_request: (required) + :type get_recommendation_unit_request: GetRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_recommendation_units_serialize( + get_recommendation_unit_request=get_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetRecommendationUnitsResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def get_recommendation_units_with_http_info( + self, + get_recommendation_unit_request: GetRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GetRecommendationUnitsResponse]: + """Retrieves all recommendation units with filters + + + :param get_recommendation_unit_request: (required) + :type get_recommendation_unit_request: GetRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_recommendation_units_serialize( + get_recommendation_unit_request=get_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetRecommendationUnitsResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def get_recommendation_units_without_preload_content( + self, + get_recommendation_unit_request: GetRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Retrieves all recommendation units with filters + + + :param get_recommendation_unit_request: (required) + :type get_recommendation_unit_request: GetRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_recommendation_units_serialize( + get_recommendation_unit_request=get_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetRecommendationUnitsResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _get_recommendation_units_serialize( + self, + get_recommendation_unit_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[str, Union[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 get_recommendation_unit_request is not None: + _body_params = get_recommendation_unit_request + + + # set the HTTP header `Accept` + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_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='/rpc/recommendation_unit_service/get_recommendation_units', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def update_recommendation_unit( + self, + update_recommendation_unit_request: UpdateRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UpdateRecommendationUnitResponse: + """Update recommendation unit + + + :param update_recommendation_unit_request: (required) + :type update_recommendation_unit_request: UpdateRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._update_recommendation_unit_serialize( + update_recommendation_unit_request=update_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UpdateRecommendationUnitResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def update_recommendation_unit_with_http_info( + self, + update_recommendation_unit_request: UpdateRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UpdateRecommendationUnitResponse]: + """Update recommendation unit + + + :param update_recommendation_unit_request: (required) + :type update_recommendation_unit_request: UpdateRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._update_recommendation_unit_serialize( + update_recommendation_unit_request=update_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UpdateRecommendationUnitResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def update_recommendation_unit_without_preload_content( + self, + update_recommendation_unit_request: UpdateRecommendationUnitRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Update recommendation unit + + + :param update_recommendation_unit_request: (required) + :type update_recommendation_unit_request: UpdateRecommendationUnitRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._update_recommendation_unit_serialize( + update_recommendation_unit_request=update_recommendation_unit_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UpdateRecommendationUnitResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _update_recommendation_unit_serialize( + self, + update_recommendation_unit_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[str, Union[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 update_recommendation_unit_request is not None: + _body_params = update_recommendation_unit_request + + + # set the HTTP header `Accept` + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_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='/rpc/recommendation_unit_service/update_recommendation_unit', + path_params=_path_params, + query_params=_query_params, + header_params=_header_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/onelens_backend_client/api/tenant_user_service_api.py b/onelens_backend_client/api/tenant_user_service_api.py index bda2a787..1a0fa4f6 100644 --- a/onelens_backend_client/api/tenant_user_service_api.py +++ b/onelens_backend_client/api/tenant_user_service_api.py @@ -26,6 +26,8 @@ from onelens_backend_client.models.get_tenant_user_by_id_response import GetTenantUserByIDResponse from onelens_backend_client.models.get_tenant_users_with_filter_request import GetTenantUsersWithFilterRequest from onelens_backend_client.models.get_tenant_users_with_filter_response import GetTenantUsersWithFilterResponse +from onelens_backend_client.models.password_change_email_request import PasswordChangeEmailRequest +from onelens_backend_client.models.password_change_email_response import PasswordChangeEmailResponse from onelens_backend_client.models.update_tenant_user_details_request import UpdateTenantUserDetailsRequest from onelens_backend_client.models.update_tenant_user_details_response import UpdateTenantUserDetailsResponse from onelens_backend_client.models.update_tenant_user_request import UpdateTenantUserRequest @@ -1107,6 +1109,276 @@ def _enable_tenant_user_serialize( + @validate_call + def enable_tenant_user_with_system( + self, + enable_tenant_user_request: EnableTenantUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EnableTenantUserResponse: + """System Enables an existing tenant user. + + + :param enable_tenant_user_request: (required) + :type enable_tenant_user_request: EnableTenantUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enable_tenant_user_with_system_serialize( + enable_tenant_user_request=enable_tenant_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnableTenantUserResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enable_tenant_user_with_system_with_http_info( + self, + enable_tenant_user_request: EnableTenantUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EnableTenantUserResponse]: + """System Enables an existing tenant user. + + + :param enable_tenant_user_request: (required) + :type enable_tenant_user_request: EnableTenantUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enable_tenant_user_with_system_serialize( + enable_tenant_user_request=enable_tenant_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnableTenantUserResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enable_tenant_user_with_system_without_preload_content( + self, + enable_tenant_user_request: EnableTenantUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """System Enables an existing tenant user. + + + :param enable_tenant_user_request: (required) + :type enable_tenant_user_request: EnableTenantUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enable_tenant_user_with_system_serialize( + enable_tenant_user_request=enable_tenant_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnableTenantUserResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enable_tenant_user_with_system_serialize( + self, + enable_tenant_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]] = {} + _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 enable_tenant_user_request is not None: + _body_params = enable_tenant_user_request + + + # set the HTTP header `Accept` + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_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='/rpc/tenant_user_service/enable_tenant_user_with_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 get_tenant_user_by_ol_user_id( self, @@ -1647,6 +1919,276 @@ def _get_tenant_users_serialize( + @validate_call + def send_email_to_user_for_password_change( + self, + password_change_email_request: PasswordChangeEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordChangeEmailResponse: + """Sends a password change email to the user. + + + :param password_change_email_request: (required) + :type password_change_email_request: PasswordChangeEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._send_email_to_user_for_password_change_serialize( + password_change_email_request=password_change_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def send_email_to_user_for_password_change_with_http_info( + self, + password_change_email_request: PasswordChangeEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordChangeEmailResponse]: + """Sends a password change email to the user. + + + :param password_change_email_request: (required) + :type password_change_email_request: PasswordChangeEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._send_email_to_user_for_password_change_serialize( + password_change_email_request=password_change_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def send_email_to_user_for_password_change_without_preload_content( + self, + password_change_email_request: PasswordChangeEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Sends a password change email to the user. + + + :param password_change_email_request: (required) + :type password_change_email_request: PasswordChangeEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._send_email_to_user_for_password_change_serialize( + password_change_email_request=password_change_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _send_email_to_user_for_password_change_serialize( + self, + password_change_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]] = {} + _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_change_email_request is not None: + _body_params = password_change_email_request + + + # set the HTTP header `Accept` + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_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='/rpc/tenant_user_service/send_email_to_user_for_password_change', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + @validate_call def update_tenant_user( self, diff --git a/onelens_backend_client/api/tenant_users_api.py b/onelens_backend_client/api/tenant_users_api.py index 133004fb..c7700cda 100644 --- a/onelens_backend_client/api/tenant_users_api.py +++ b/onelens_backend_client/api/tenant_users_api.py @@ -21,7 +21,9 @@ from onelens_backend_client.models.get_tenant_users_with_filter_api_request import GetTenantUsersWithFilterAPIRequest from onelens_backend_client.models.response_create_tenant_user_response import ResponseCreateTenantUserResponse from onelens_backend_client.models.response_get_tenant_user_by_id_response import ResponseGetTenantUserByIDResponse +from onelens_backend_client.models.response_get_tenant_user_profile_response import ResponseGetTenantUserProfileResponse from onelens_backend_client.models.response_get_tenant_users_with_filter_response import ResponseGetTenantUsersWithFilterResponse +from onelens_backend_client.models.response_password_change_email_response import ResponsePasswordChangeEmailResponse from onelens_backend_client.models.response_update_tenant_user_details_response import ResponseUpdateTenantUserDetailsResponse from onelens_backend_client.models.response_update_tenant_user_response import ResponseUpdateTenantUserResponse from onelens_backend_client.models.tenant_user_details_update_fields_mixin import TenantUserDetailsUpdateFieldsMixin @@ -2757,6 +2759,1037 @@ def _get_tenant_user_by_ol_user_id_0_serialize( + @validate_call + def get_tenant_user_profile( + self, + tenant_id: 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, + ) -> ResponseGetTenantUserProfileResponse: + """Get user profile from the Tenant Database. + + Get user profile in the Tenant Database. + + :param tenant_id: (required) + :type tenant_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._get_tenant_user_profile_serialize( + tenant_id=tenant_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponseGetTenantUserProfileResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def get_tenant_user_profile_with_http_info( + self, + tenant_id: 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[ResponseGetTenantUserProfileResponse]: + """Get user profile from the Tenant Database. + + Get user profile in the Tenant Database. + + :param tenant_id: (required) + :type tenant_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._get_tenant_user_profile_serialize( + tenant_id=tenant_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponseGetTenantUserProfileResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def get_tenant_user_profile_without_preload_content( + self, + tenant_id: 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: + """Get user profile from the Tenant Database. + + Get user profile in the Tenant Database. + + :param tenant_id: (required) + :type tenant_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._get_tenant_user_profile_serialize( + tenant_id=tenant_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponseGetTenantUserProfileResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _get_tenant_user_profile_serialize( + self, + tenant_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]] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if tenant_id is not None: + _path_params['tenant_id'] = tenant_id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + _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='/v1/tenants/{tenant_id}/user/profile', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def get_tenant_user_profile_0( + 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, + ) -> ResponseGetTenantUserProfileResponse: + """Get Tenant User Profile + + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_tenant_user_profile_0_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponseGetTenantUserProfileResponse", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def get_tenant_user_profile_0_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[ResponseGetTenantUserProfileResponse]: + """Get Tenant User Profile + + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_tenant_user_profile_0_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponseGetTenantUserProfileResponse", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def get_tenant_user_profile_0_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: + """Get Tenant User Profile + + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_tenant_user_profile_0_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponseGetTenantUserProfileResponse", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _get_tenant_user_profile_0_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]] = {} + _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` + _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='/v1/user/profile', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def send_email_to_user_for_password_change( + self, + tenant_id: StrictStr, + ol_user_id: 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, + ) -> ResponsePasswordChangeEmailResponse: + """Send user password change email. + + Send user password change email. + + :param tenant_id: (required) + :type tenant_id: str + :param ol_user_id: (required) + :type ol_user_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._send_email_to_user_for_password_change_serialize( + tenant_id=tenant_id, + ol_user_id=ol_user_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponsePasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def send_email_to_user_for_password_change_with_http_info( + self, + tenant_id: StrictStr, + ol_user_id: 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[ResponsePasswordChangeEmailResponse]: + """Send user password change email. + + Send user password change email. + + :param tenant_id: (required) + :type tenant_id: str + :param ol_user_id: (required) + :type ol_user_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._send_email_to_user_for_password_change_serialize( + tenant_id=tenant_id, + ol_user_id=ol_user_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponsePasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def send_email_to_user_for_password_change_without_preload_content( + self, + tenant_id: StrictStr, + ol_user_id: 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: + """Send user password change email. + + Send user password change email. + + :param tenant_id: (required) + :type tenant_id: str + :param ol_user_id: (required) + :type ol_user_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._send_email_to_user_for_password_change_serialize( + tenant_id=tenant_id, + ol_user_id=ol_user_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponsePasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _send_email_to_user_for_password_change_serialize( + self, + tenant_id, + ol_user_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]] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if tenant_id is not None: + _path_params['tenant_id'] = tenant_id + if ol_user_id is not None: + _path_params['ol_user_id'] = ol_user_id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + _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='/v1/tenants/{tenant_id}/users/{ol_user_id}/reset_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 send_email_to_user_for_password_change_0( + self, + ol_user_id: 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, + ) -> ResponsePasswordChangeEmailResponse: + """Send Email To User For Password Change + + + :param ol_user_id: (required) + :type ol_user_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._send_email_to_user_for_password_change_0_serialize( + ol_user_id=ol_user_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponsePasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def send_email_to_user_for_password_change_0_with_http_info( + self, + ol_user_id: 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[ResponsePasswordChangeEmailResponse]: + """Send Email To User For Password Change + + + :param ol_user_id: (required) + :type ol_user_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._send_email_to_user_for_password_change_0_serialize( + ol_user_id=ol_user_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponsePasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def send_email_to_user_for_password_change_0_without_preload_content( + self, + ol_user_id: 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: + """Send Email To User For Password Change + + + :param ol_user_id: (required) + :type ol_user_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._send_email_to_user_for_password_change_0_serialize( + ol_user_id=ol_user_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ResponsePasswordChangeEmailResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _send_email_to_user_for_password_change_0_serialize( + self, + ol_user_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]] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if ol_user_id is not None: + _path_params['ol_user_id'] = ol_user_id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + _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='/v1/users/{ol_user_id}/reset_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 update_tenant_user( self, diff --git a/onelens_backend_client/models/__init__.py b/onelens_backend_client/models/__init__.py index 54057a95..5c126029 100644 --- a/onelens_backend_client/models/__init__.py +++ b/onelens_backend_client/models/__init__.py @@ -14,6 +14,9 @@ # import models into model package +from onelens_backend_client.models.action_type import ActionType +from onelens_backend_client.models.action_type_filters import ActionTypeFilters +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.activate_policy_template_request import ActivatePolicyTemplateRequest from onelens_backend_client.models.add_tenant_policy_exclusions_api_request import AddTenantPolicyExclusionsAPIRequest from onelens_backend_client.models.add_tenant_policy_exclusions_request import AddTenantPolicyExclusionsRequest @@ -35,6 +38,8 @@ from onelens_backend_client.models.bulk_update_tenant_tickets_response import BulkUpdateTenantTicketsResponse from onelens_backend_client.models.city import City from onelens_backend_client.models.country import Country +from onelens_backend_client.models.create_action_type_request import CreateActionTypeRequest +from onelens_backend_client.models.create_action_type_response import CreateActionTypeResponse from onelens_backend_client.models.create_auth0_and_onelens_user_response import CreateAuth0AndOnelensUserResponse from onelens_backend_client.models.create_auth0_user_request import CreateAuth0UserRequest from onelens_backend_client.models.create_default_hierarchy_request import CreateDefaultHierarchyRequest @@ -49,8 +54,9 @@ from onelens_backend_client.models.create_policy_template_pack_request import CreatePolicyTemplatePackRequest from onelens_backend_client.models.create_policy_template_pack_response import CreatePolicyTemplatePackResponse from onelens_backend_client.models.create_policy_template_request import CreatePolicyTemplateRequest -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner from onelens_backend_client.models.create_policy_template_response import CreatePolicyTemplateResponse +from onelens_backend_client.models.create_recommendation_unit_request import CreateRecommendationUnitRequest +from onelens_backend_client.models.create_recommendation_unit_response import CreateRecommendationUnitResponse from onelens_backend_client.models.create_tenant_provider_request import CreateTenantProviderRequest from onelens_backend_client.models.create_tenant_provider_response import CreateTenantProviderResponse from onelens_backend_client.models.create_tenant_request_with_user import CreateTenantRequestWithUser @@ -75,7 +81,6 @@ from onelens_backend_client.models.deactivate_policy_template_request import DeactivatePolicyTemplateRequest from onelens_backend_client.models.delete_hierarchy_node_request import DeleteHierarchyNodeRequest from onelens_backend_client.models.deprecate_policy_template_request import DeprecatePolicyTemplateRequest -from onelens_backend_client.models.derived_variable import DerivedVariable from onelens_backend_client.models.details import Details from onelens_backend_client.models.details1 import Details1 from onelens_backend_client.models.details2 import Details2 @@ -101,6 +106,8 @@ from onelens_backend_client.models.features import Features from onelens_backend_client.models.first_name import FirstName from onelens_backend_client.models.gcp_service import GcpService +from onelens_backend_client.models.get_action_type_request import GetActionTypeRequest +from onelens_backend_client.models.get_action_type_response import GetActionTypeResponse from onelens_backend_client.models.get_all_policy_violations_api_request import GetAllPolicyViolationsAPIRequest from onelens_backend_client.models.get_all_policy_violations_request import GetAllPolicyViolationsRequest from onelens_backend_client.models.get_all_policy_violations_response import GetAllPolicyViolationsResponse @@ -145,6 +152,7 @@ from onelens_backend_client.models.get_recommendation_ticket_response import GetRecommendationTicketResponse from onelens_backend_client.models.get_recommendation_unit_by_id_request import GetRecommendationUnitByIdRequest from onelens_backend_client.models.get_recommendation_unit_by_id_response import GetRecommendationUnitByIdResponse +from onelens_backend_client.models.get_recommendation_unit_request import GetRecommendationUnitRequest from onelens_backend_client.models.get_recommendation_units_request import GetRecommendationUnitsRequest from onelens_backend_client.models.get_recommendation_units_response import GetRecommendationUnitsResponse from onelens_backend_client.models.get_resource_hierarchy_mapping_by_ol_id_request import GetResourceHierarchyMappingByOlIdRequest @@ -180,6 +188,7 @@ from onelens_backend_client.models.get_tenant_tickets_response import GetTenantTicketsResponse from onelens_backend_client.models.get_tenant_user_by_id_request import GetTenantUserByIDRequest from onelens_backend_client.models.get_tenant_user_by_id_response import GetTenantUserByIDResponse +from onelens_backend_client.models.get_tenant_user_profile_response import GetTenantUserProfileResponse from onelens_backend_client.models.get_tenant_users_with_filter_api_request import GetTenantUsersWithFilterAPIRequest from onelens_backend_client.models.get_tenant_users_with_filter_request import GetTenantUsersWithFilterRequest from onelens_backend_client.models.get_tenant_users_with_filter_response import GetTenantUsersWithFilterResponse @@ -234,6 +243,8 @@ from onelens_backend_client.models.override_tenant_policy_exclusions_response import OverrideTenantPolicyExclusionsResponse from onelens_backend_client.models.pagination_fields import PaginationFields from onelens_backend_client.models.pagination_params import PaginationParams +from onelens_backend_client.models.password_change_email_request import PasswordChangeEmailRequest +from onelens_backend_client.models.password_change_email_response import PasswordChangeEmailResponse from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_recommendation_params import PolicyRecommendationParams @@ -258,7 +269,7 @@ from onelens_backend_client.models.provider_config_input import ProviderConfigInput from onelens_backend_client.models.provider_config_output import ProviderConfigOutput from onelens_backend_client.models.publish_custom_hierarchy_request import PublishCustomHierarchyRequest -from onelens_backend_client.models.query_details import QueryDetails +from onelens_backend_client.models.query_details_derived_variables import QueryDetailsDerivedVariables from onelens_backend_client.models.query_filters import QueryFilters from onelens_backend_client.models.query_order import QueryOrder from onelens_backend_client.models.recommendation_engine import RecommendationEngine @@ -266,11 +277,14 @@ from onelens_backend_client.models.recommendation_engine_request import RecommendationEngineRequest from onelens_backend_client.models.recommendation_engine_response import RecommendationEngineResponse from onelens_backend_client.models.recommendation_params import RecommendationParams +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails from onelens_backend_client.models.recommendation_ticket import RecommendationTicket from onelens_backend_client.models.recommendation_ticket_api_request_input import RecommendationTicketAPIRequestInput from onelens_backend_client.models.recommendation_ticket_api_request_output import RecommendationTicketAPIRequestOutput from onelens_backend_client.models.recommendation_ticket_request import RecommendationTicketRequest from onelens_backend_client.models.recommendation_ticket_response import RecommendationTicketResponse +from onelens_backend_client.models.recommendation_unit import RecommendationUnit +from onelens_backend_client.models.recommendation_unit_filters import RecommendationUnitFilters from onelens_backend_client.models.relationship_config_item import RelationshipConfigItem from onelens_backend_client.models.resource_catalog import ResourceCatalog from onelens_backend_client.models.resource_catalog_request import ResourceCatalogRequest @@ -321,11 +335,13 @@ from onelens_backend_client.models.response_get_tenant_providers_response import ResponseGetTenantProvidersResponse from onelens_backend_client.models.response_get_tenant_tickets_response import ResponseGetTenantTicketsResponse from onelens_backend_client.models.response_get_tenant_user_by_id_response import ResponseGetTenantUserByIDResponse +from onelens_backend_client.models.response_get_tenant_user_profile_response import ResponseGetTenantUserProfileResponse from onelens_backend_client.models.response_get_tenant_users_with_filter_response import ResponseGetTenantUsersWithFilterResponse from onelens_backend_client.models.response_get_tenants_response import ResponseGetTenantsResponse from onelens_backend_client.models.response_get_ticket_by_id_policy_details_response import ResponseGetTicketByIdPolicyDetailsResponse from onelens_backend_client.models.response_override_tenant_anomaly_config_response import ResponseOverrideTenantAnomalyConfigResponse from onelens_backend_client.models.response_override_tenant_policy_exclusions_response import ResponseOverrideTenantPolicyExclusionsResponse +from onelens_backend_client.models.response_password_change_email_response import ResponsePasswordChangeEmailResponse from onelens_backend_client.models.response_recommendation_engine_response import ResponseRecommendationEngineResponse from onelens_backend_client.models.response_recommendation_ticket_response import ResponseRecommendationTicketResponse from onelens_backend_client.models.response_resource_catalog_response import ResponseResourceCatalogResponse @@ -340,11 +356,11 @@ from onelens_backend_client.models.response_update_tenant_user_details_response import ResponseUpdateTenantUserDetailsResponse from onelens_backend_client.models.response_update_tenant_user_response import ResponseUpdateTenantUserResponse from onelens_backend_client.models.rule_type import RuleType +from onelens_backend_client.models.service import Service from onelens_backend_client.models.service_catalog import ServiceCatalog from onelens_backend_client.models.service_catalog_request import ServiceCatalogRequest from onelens_backend_client.models.service_catalog_request_find import ServiceCatalogRequestFind from onelens_backend_client.models.service_catalog_response import ServiceCatalogResponse -from onelens_backend_client.models.service_config import ServiceConfig from onelens_backend_client.models.set_tenant_status_request import SetTenantStatusRequest from onelens_backend_client.models.sort_criteria import SortCriteria from onelens_backend_client.models.sources import Sources @@ -352,6 +368,7 @@ from onelens_backend_client.models.status import Status from onelens_backend_client.models.status1 import Status1 from onelens_backend_client.models.statuses import Statuses +from onelens_backend_client.models.storage_lens_config import StorageLensConfig from onelens_backend_client.models.tenant import Tenant from onelens_backend_client.models.tenant_anomaly_setting_filters import TenantAnomalySettingFilters from onelens_backend_client.models.tenant_anomaly_settings import TenantAnomalySettings @@ -390,6 +407,8 @@ from onelens_backend_client.models.time_dimension_output import TimeDimensionOutput from onelens_backend_client.models.time_dimension_output_compare_date_range_inner import TimeDimensionOutputCompareDateRangeInner from onelens_backend_client.models.timezone import Timezone +from onelens_backend_client.models.update_action_type_request import UpdateActionTypeRequest +from onelens_backend_client.models.update_action_type_response import UpdateActionTypeResponse from onelens_backend_client.models.update_hierarchy_node_api_request import UpdateHierarchyNodeAPIRequest from onelens_backend_client.models.update_hierarchy_node_request import UpdateHierarchyNodeRequest from onelens_backend_client.models.update_hierarchy_node_response import UpdateHierarchyNodeResponse @@ -397,6 +416,8 @@ from onelens_backend_client.models.update_organization_response import UpdateOrganizationResponse from onelens_backend_client.models.update_policy_template_request import UpdatePolicyTemplateRequest from onelens_backend_client.models.update_policy_template_response import UpdatePolicyTemplateResponse +from onelens_backend_client.models.update_recommendation_unit_request import UpdateRecommendationUnitRequest +from onelens_backend_client.models.update_recommendation_unit_response import UpdateRecommendationUnitResponse from onelens_backend_client.models.update_tenant_policy_setting_last_run_at_request import UpdateTenantPolicySettingLastRunAtRequest from onelens_backend_client.models.update_tenant_request import UpdateTenantRequest from onelens_backend_client.models.update_tenant_response import UpdateTenantResponse diff --git a/onelens_backend_client/models/action_type.py b/onelens_backend_client/models/action_type.py new file mode 100644 index 00000000..adcf6b12 --- /dev/null +++ b/onelens_backend_client/models/action_type.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.service import Service +from typing import Optional, Set +from typing_extensions import Self + +class ActionType(BaseModel): + """ + ActionType + """ # noqa: E501 + service: Service + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + id: StrictInt = Field(description="Action Type ID") + __properties: ClassVar[List[str]] = ["service", "title", "subtitle", "description", "id"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ActionType from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 service + if self.service: + _dict['service'] = self.service.to_dict() + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ActionType from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "service": Service.from_dict(obj["service"]) if obj.get("service") is not None else None, + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "id": obj.get("id") + }) + return _obj + + diff --git a/onelens_backend_client/models/action_type_filters.py b/onelens_backend_client/models/action_type_filters.py new file mode 100644 index 00000000..ee62fa3f --- /dev/null +++ b/onelens_backend_client/models/action_type_filters.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner +from typing import Optional, Set +from typing_extensions import Self + +class ActionTypeFilters(BaseModel): + """ + ActionTypeFilters + """ # noqa: E501 + search_query: Optional[StrictStr] = None + ids: Optional[List[StrictInt]] = Field(default=None, description="Filter by recommendation unit id/alias.") + services: Optional[List[ActionTypeFiltersServicesInner]] = Field(default=None, description="Filter by Services") + __properties: ClassVar[List[str]] = ["search_query", "ids", "services"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ActionTypeFilters from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 services (list) + _items = [] + if self.services: + for _item in self.services: + if _item: + _items.append(_item.to_dict()) + _dict['services'] = _items + # set to None if search_query (nullable) is None + # and model_fields_set contains the field + if self.search_query is None and "search_query" in self.model_fields_set: + _dict['search_query'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ActionTypeFilters from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "search_query": obj.get("search_query"), + "ids": obj.get("ids"), + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None + }) + return _obj + + diff --git a/onelens_backend_client/models/action_type_filters_services_inner.py b/onelens_backend_client/models/action_type_filters_services_inner.py new file mode 100644 index 00000000..7c7cf949 --- /dev/null +++ b/onelens_backend_client/models/action_type_filters_services_inner.py @@ -0,0 +1,134 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +from inspect import getfullargspec +import json +import pprint +import re # noqa: F401 +from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator +from typing import Optional +from onelens_backend_client.models.aws_service import AwsService +from onelens_backend_client.models.gcp_service import GcpService +from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict +from typing_extensions import Literal, Self +from pydantic import Field + +ACTIONTYPEFILTERSSERVICESINNER_ANY_OF_SCHEMAS = ["AwsService", "GcpService"] + +class ActionTypeFiltersServicesInner(BaseModel): + """ + ActionTypeFiltersServicesInner + """ + + # data type: AwsService + anyof_schema_1_validator: Optional[AwsService] = None + # data type: GcpService + anyof_schema_2_validator: Optional[GcpService] = None + if TYPE_CHECKING: + actual_instance: Optional[Union[AwsService, GcpService]] = None + else: + actual_instance: Any = None + any_of_schemas: Set[str] = { "AwsService", "GcpService" } + + model_config = { + "validate_assignment": True, + "protected_namespaces": (), + } + + 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_anyof(cls, v): + instance = ActionTypeFiltersServicesInner.model_construct() + error_messages = [] + # validate data type: AwsService + if not isinstance(v, AwsService): + error_messages.append(f"Error! Input type `{type(v)}` is not `AwsService`") + else: + return v + + # validate data type: GcpService + if not isinstance(v, GcpService): + error_messages.append(f"Error! Input type `{type(v)}` is not `GcpService`") + else: + return v + + if error_messages: + # no match + raise ValueError("No match found when setting the actual_instance in ActionTypeFiltersServicesInner with anyOf schemas: AwsService, GcpService. Details: " + ", ".join(error_messages)) + else: + return v + + @classmethod + def from_dict(cls, obj: 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 = [] + # anyof_schema_1_validator: Optional[AwsService] = None + try: + instance.actual_instance = AwsService.from_json(json_str) + return instance + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # anyof_schema_2_validator: Optional[GcpService] = None + try: + instance.actual_instance = GcpService.from_json(json_str) + return instance + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + + if error_messages: + # no match + raise ValueError("No match found when deserializing the JSON string into ActionTypeFiltersServicesInner with anyOf schemas: AwsService, GcpService. 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], AwsService, GcpService]]: + """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: + 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/onelens_backend_client/models/create_action_type_request.py b/onelens_backend_client/models/create_action_type_request.py new file mode 100644 index 00000000..c2d8e2b5 --- /dev/null +++ b/onelens_backend_client/models/create_action_type_request.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.service import Service +from typing import Optional, Set +from typing_extensions import Self + +class CreateActionTypeRequest(BaseModel): + """ + CreateActionTypeRequest + """ # noqa: E501 + service: Service + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + __properties: ClassVar[List[str]] = ["service", "title", "subtitle", "description"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CreateActionTypeRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 service + if self.service: + _dict['service'] = self.service.to_dict() + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CreateActionTypeRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "service": Service.from_dict(obj["service"]) if obj.get("service") is not None else None, + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description") + }) + return _obj + + diff --git a/onelens_backend_client/models/create_action_type_response.py b/onelens_backend_client/models/create_action_type_response.py new file mode 100644 index 00000000..a11830d3 --- /dev/null +++ b/onelens_backend_client/models/create_action_type_response.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.service import Service +from typing import Optional, Set +from typing_extensions import Self + +class CreateActionTypeResponse(BaseModel): + """ + CreateActionTypeResponse + """ # noqa: E501 + service: Service + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + id: StrictInt = Field(description="Action Type ID") + __properties: ClassVar[List[str]] = ["service", "title", "subtitle", "description", "id"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CreateActionTypeResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 service + if self.service: + _dict['service'] = self.service.to_dict() + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CreateActionTypeResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "service": Service.from_dict(obj["service"]) if obj.get("service") is not None else None, + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "id": obj.get("id") + }) + return _obj + + diff --git a/onelens_backend_client/models/create_policy_template_request.py b/onelens_backend_client/models/create_policy_template_request.py index 37eb5a14..4a07b88c 100644 --- a/onelens_backend_client/models/create_policy_template_request.py +++ b/onelens_backend_client/models/create_policy_template_request.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_input import PolicyTemplateDetailsInput from onelens_backend_client.models.policy_template_recommendation_details_input import PolicyTemplateRecommendationDetailsInput @@ -34,7 +34,7 @@ class CreatePolicyTemplateRequest(BaseModel): title: StrictStr = Field(description="The title of the policy template.") alias: StrictStr = Field(description="The alias of the policy template.") description: Optional[StrictStr] = Field(default=None, description="The description of the policy template.") - services: List[CreatePolicyTemplateRequestServicesInner] = Field(description="The list of services associated the policy template.") + services: List[ActionTypeFiltersServicesInner] = Field(description="The list of services associated the policy template.") execution_type: PolicyExecutionType = Field(description="The execution type of the policy template.") details: PolicyTemplateDetailsInput = Field(description="The details of the policy template.") description2: Optional[StrictStr] = Field(default=None, description="The description2 of the policy template.") @@ -110,7 +110,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "title": obj.get("title"), "alias": obj.get("alias"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsInput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/create_policy_template_response.py b/onelens_backend_client/models/create_policy_template_response.py index d982266f..99339648 100644 --- a/onelens_backend_client/models/create_policy_template_response.py +++ b/onelens_backend_client/models/create_policy_template_response.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_output import PolicyTemplateDetailsOutput @@ -37,7 +37,7 @@ class CreatePolicyTemplateResponse(BaseModel): title: StrictStr = Field(description="The title of the policy template.") alias: StrictStr = Field(description="The alias of the policy template.") description: Optional[StrictStr] = Field(default=None, description="The description of the policy template.") - services: List[CreatePolicyTemplateRequestServicesInner] = Field(description="The list of services associated the policy template.") + services: List[ActionTypeFiltersServicesInner] = Field(description="The list of services associated the policy template.") execution_type: PolicyExecutionType = Field(description="The execution type of the policy template.") details: PolicyTemplateDetailsOutput = Field(description="The details of the policy template.") description2: Optional[StrictStr] = Field(default=None, description="The description2 of the policy template.") @@ -117,7 +117,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "title": obj.get("title"), "alias": obj.get("alias"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsOutput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/create_recommendation_unit_request.py b/onelens_backend_client/models/create_recommendation_unit_request.py new file mode 100644 index 00000000..424275ec --- /dev/null +++ b/onelens_backend_client/models/create_recommendation_unit_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.effort import Effort +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails +from typing import Optional, Set +from typing_extensions import Self + +class CreateRecommendationUnitRequest(BaseModel): + """ + CreateRecommendationUnitRequest + """ # noqa: E501 + id: StrictStr = Field(description="Recommendation Config ID") + service: StrictStr = Field(description="Service AWS etc.") + action_type_id: Optional[StrictInt] = None + priority: StrictInt = Field(description="Priority") + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + effort: Effort = Field(description="Effort") + query_details: Optional[RecommendationQueryDetails] + __properties: ClassVar[List[str]] = ["id", "service", "action_type_id", "priority", "title", "subtitle", "description", "effort", "query_details"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CreateRecommendationUnitRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 query_details + if self.query_details: + _dict['query_details'] = self.query_details.to_dict() + # set to None if action_type_id (nullable) is None + # and model_fields_set contains the field + if self.action_type_id is None and "action_type_id" in self.model_fields_set: + _dict['action_type_id'] = None + + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + # set to None if query_details (nullable) is None + # and model_fields_set contains the field + if self.query_details is None and "query_details" in self.model_fields_set: + _dict['query_details'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CreateRecommendationUnitRequest 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"), + "service": obj.get("service"), + "action_type_id": obj.get("action_type_id"), + "priority": obj.get("priority"), + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "effort": obj.get("effort"), + "query_details": RecommendationQueryDetails.from_dict(obj["query_details"]) if obj.get("query_details") is not None else None + }) + return _obj + + diff --git a/onelens_backend_client/models/create_recommendation_unit_response.py b/onelens_backend_client/models/create_recommendation_unit_response.py new file mode 100644 index 00000000..07ff8504 --- /dev/null +++ b/onelens_backend_client/models/create_recommendation_unit_response.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.effort import Effort +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails +from typing import Optional, Set +from typing_extensions import Self + +class CreateRecommendationUnitResponse(BaseModel): + """ + CreateRecommendationUnitResponse + """ # noqa: E501 + id: StrictStr = Field(description="Recommendation Config ID") + service: StrictStr = Field(description="Service AWS etc.") + action_type_id: Optional[StrictInt] = None + priority: StrictInt = Field(description="Priority") + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + effort: Effort = Field(description="Effort") + query_details: Optional[RecommendationQueryDetails] + __properties: ClassVar[List[str]] = ["id", "service", "action_type_id", "priority", "title", "subtitle", "description", "effort", "query_details"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CreateRecommendationUnitResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 query_details + if self.query_details: + _dict['query_details'] = self.query_details.to_dict() + # set to None if action_type_id (nullable) is None + # and model_fields_set contains the field + if self.action_type_id is None and "action_type_id" in self.model_fields_set: + _dict['action_type_id'] = None + + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + # set to None if query_details (nullable) is None + # and model_fields_set contains the field + if self.query_details is None and "query_details" in self.model_fields_set: + _dict['query_details'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CreateRecommendationUnitResponse 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"), + "service": obj.get("service"), + "action_type_id": obj.get("action_type_id"), + "priority": obj.get("priority"), + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "effort": obj.get("effort"), + "query_details": RecommendationQueryDetails.from_dict(obj["query_details"]) if obj.get("query_details") is not None else None + }) + return _obj + + diff --git a/onelens_backend_client/models/get_action_type_request.py b/onelens_backend_client/models/get_action_type_request.py new file mode 100644 index 00000000..60b6aba0 --- /dev/null +++ b/onelens_backend_client/models/get_action_type_request.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.action_type_filters import ActionTypeFilters +from onelens_backend_client.models.pagination_params import PaginationParams +from typing import Optional, Set +from typing_extensions import Self + +class GetActionTypeRequest(BaseModel): + """ + GetActionTypeRequest + """ # noqa: E501 + pagination: Optional[PaginationParams] = Field(default=None, description="Pagination parameters for the request.") + filters: Optional[ActionTypeFilters] = Field(default=None, description="Filters to apply to the Action Types.") + __properties: ClassVar[List[str]] = ["pagination", "filters"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GetActionTypeRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 filters + if self.filters: + _dict['filters'] = self.filters.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GetActionTypeRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": PaginationParams.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "filters": ActionTypeFilters.from_dict(obj["filters"]) if obj.get("filters") is not None else None + }) + return _obj + + diff --git a/onelens_backend_client/models/get_action_type_response.py b/onelens_backend_client/models/get_action_type_response.py new file mode 100644 index 00000000..8cdac8e1 --- /dev/null +++ b/onelens_backend_client/models/get_action_type_response.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.action_type import ActionType +from onelens_backend_client.models.pagination_fields import PaginationFields +from typing import Optional, Set +from typing_extensions import Self + +class GetActionTypeResponse(BaseModel): + """ + GetActionTypeResponse + """ # noqa: E501 + action_types: List[ActionType] = Field(description="Action Types") + pagination: PaginationFields = Field(description="Pagination fields") + __properties: ClassVar[List[str]] = ["action_types", "pagination"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GetActionTypeResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 action_types (list) + _items = [] + if self.action_types: + for _item in self.action_types: + if _item: + _items.append(_item.to_dict()) + _dict['action_types'] = _items + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GetActionTypeResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "action_types": [ActionType.from_dict(_item) for _item in obj["action_types"]] if obj.get("action_types") is not None else None, + "pagination": PaginationFields.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None + }) + return _obj + + diff --git a/onelens_backend_client/models/get_policy_template_by_id_response.py b/onelens_backend_client/models/get_policy_template_by_id_response.py index 1de92952..629f4e80 100644 --- a/onelens_backend_client/models/get_policy_template_by_id_response.py +++ b/onelens_backend_client/models/get_policy_template_by_id_response.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_output import PolicyTemplateDetailsOutput @@ -37,7 +37,7 @@ class GetPolicyTemplateByIDResponse(BaseModel): title: StrictStr = Field(description="The title of the policy template.") alias: StrictStr = Field(description="The alias of the policy template.") description: Optional[StrictStr] = Field(default=None, description="The description of the policy template.") - services: List[CreatePolicyTemplateRequestServicesInner] = Field(description="The list of services associated the policy template.") + services: List[ActionTypeFiltersServicesInner] = Field(description="The list of services associated the policy template.") execution_type: PolicyExecutionType = Field(description="The execution type of the policy template.") details: PolicyTemplateDetailsOutput = Field(description="The details of the policy template.") description2: Optional[StrictStr] = Field(default=None, description="The description2 of the policy template.") @@ -117,7 +117,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "title": obj.get("title"), "alias": obj.get("alias"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsOutput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/get_recommendation_unit_by_id_response.py b/onelens_backend_client/models/get_recommendation_unit_by_id_response.py index 95af6246..0d172a44 100644 --- a/onelens_backend_client/models/get_recommendation_unit_by_id_response.py +++ b/onelens_backend_client/models/get_recommendation_unit_by_id_response.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field from typing import Any, ClassVar, Dict, List -from onelens_backend_client.models.service_config import ServiceConfig +from onelens_backend_client.models.recommendation_unit import RecommendationUnit from typing import Optional, Set from typing_extensions import Self @@ -27,7 +27,7 @@ class GetRecommendationUnitByIdResponse(BaseModel): """ GetRecommendationUnitByIdResponse """ # noqa: E501 - recommendation_unit: ServiceConfig = Field(description="Recommendation Unit") + recommendation_unit: RecommendationUnit = Field(description="Recommendation Unit") __properties: ClassVar[List[str]] = ["recommendation_unit"] model_config = ConfigDict( @@ -84,7 +84,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "recommendation_unit": ServiceConfig.from_dict(obj["recommendation_unit"]) if obj.get("recommendation_unit") is not None else None + "recommendation_unit": RecommendationUnit.from_dict(obj["recommendation_unit"]) if obj.get("recommendation_unit") is not None else None }) return _obj diff --git a/onelens_backend_client/models/get_recommendation_unit_request.py b/onelens_backend_client/models/get_recommendation_unit_request.py new file mode 100644 index 00000000..26d755d9 --- /dev/null +++ b/onelens_backend_client/models/get_recommendation_unit_request.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.pagination_params import PaginationParams +from onelens_backend_client.models.recommendation_unit_filters import RecommendationUnitFilters +from typing import Optional, Set +from typing_extensions import Self + +class GetRecommendationUnitRequest(BaseModel): + """ + GetRecommendationUnitRequest + """ # noqa: E501 + pagination: Optional[PaginationParams] = Field(default=None, description="Pagination parameters for the request.") + filters: Optional[RecommendationUnitFilters] = Field(default=None, description="Filters to apply to the Recommendation Unit.") + __properties: ClassVar[List[str]] = ["pagination", "filters"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GetRecommendationUnitRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 filters + if self.filters: + _dict['filters'] = self.filters.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GetRecommendationUnitRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": PaginationParams.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "filters": RecommendationUnitFilters.from_dict(obj["filters"]) if obj.get("filters") is not None else None + }) + return _obj + + diff --git a/onelens_backend_client/models/get_recommendation_units_response.py b/onelens_backend_client/models/get_recommendation_units_response.py index a8d216e2..2fbfc8b5 100644 --- a/onelens_backend_client/models/get_recommendation_units_response.py +++ b/onelens_backend_client/models/get_recommendation_units_response.py @@ -19,7 +19,8 @@ from pydantic import BaseModel, ConfigDict, Field from typing import Any, ClassVar, Dict, List -from onelens_backend_client.models.service_config import ServiceConfig +from onelens_backend_client.models.pagination_fields import PaginationFields +from onelens_backend_client.models.recommendation_unit import RecommendationUnit from typing import Optional, Set from typing_extensions import Self @@ -27,8 +28,9 @@ class GetRecommendationUnitsResponse(BaseModel): """ GetRecommendationUnitsResponse """ # noqa: E501 - recommendation_units: List[ServiceConfig] = Field(description="Recommendation Unit") - __properties: ClassVar[List[str]] = ["recommendation_units"] + recommendation_units: List[RecommendationUnit] = Field(description="Recommendation Unit") + pagination: PaginationFields = Field(description="Pagination fields") + __properties: ClassVar[List[str]] = ["recommendation_units", "pagination"] model_config = ConfigDict( populate_by_name=True, @@ -76,6 +78,9 @@ def to_dict(self) -> Dict[str, Any]: if _item: _items.append(_item.to_dict()) _dict['recommendation_units'] = _items + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() return _dict @classmethod @@ -88,7 +93,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "recommendation_units": [ServiceConfig.from_dict(_item) for _item in obj["recommendation_units"]] if obj.get("recommendation_units") is not None else None + "recommendation_units": [RecommendationUnit.from_dict(_item) for _item in obj["recommendation_units"]] if obj.get("recommendation_units") is not None else None, + "pagination": PaginationFields.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None }) return _obj diff --git a/onelens_backend_client/models/get_tenant_policies_with_settings_api_request.py b/onelens_backend_client/models/get_tenant_policies_with_settings_api_request.py index dbbbf73d..27cfec8f 100644 --- a/onelens_backend_client/models/get_tenant_policies_with_settings_api_request.py +++ b/onelens_backend_client/models/get_tenant_policies_with_settings_api_request.py @@ -21,6 +21,7 @@ from typing import Any, ClassVar, Dict, List, Optional from onelens_backend_client.models.onelens_domain_utilities_repositories_dynamic_filters_filter_criteria import OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria from onelens_backend_client.models.pagination_params import PaginationParams +from onelens_backend_client.models.sort_criteria import SortCriteria from typing import Optional, Set from typing_extensions import Self @@ -30,7 +31,8 @@ class GetTenantPoliciesWithSettingsAPIRequest(BaseModel): """ # noqa: E501 pagination: Optional[PaginationParams] = Field(default=None, description="Pagination parameters for the request.") filters: List[OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria] = Field(description="Filters to be applied") - __properties: ClassVar[List[str]] = ["pagination", "filters"] + sort_criteria: Optional[SortCriteria] = None + __properties: ClassVar[List[str]] = ["pagination", "filters", "sort_criteria"] model_config = ConfigDict( populate_by_name=True, @@ -81,6 +83,14 @@ def to_dict(self) -> Dict[str, Any]: if _item: _items.append(_item.to_dict()) _dict['filters'] = _items + # override the default output from pydantic by calling `to_dict()` of sort_criteria + if self.sort_criteria: + _dict['sort_criteria'] = self.sort_criteria.to_dict() + # set to None if sort_criteria (nullable) is None + # and model_fields_set contains the field + if self.sort_criteria is None and "sort_criteria" in self.model_fields_set: + _dict['sort_criteria'] = None + return _dict @classmethod @@ -94,7 +104,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "pagination": PaginationParams.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, - "filters": [OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria.from_dict(_item) for _item in obj["filters"]] if obj.get("filters") is not None else None + "filters": [OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria.from_dict(_item) for _item in obj["filters"]] if obj.get("filters") is not None else None, + "sort_criteria": SortCriteria.from_dict(obj["sort_criteria"]) if obj.get("sort_criteria") is not None else None }) return _obj diff --git a/onelens_backend_client/models/get_tenant_policies_with_settings_request.py b/onelens_backend_client/models/get_tenant_policies_with_settings_request.py index c3368622..e7044f7f 100644 --- a/onelens_backend_client/models/get_tenant_policies_with_settings_request.py +++ b/onelens_backend_client/models/get_tenant_policies_with_settings_request.py @@ -21,6 +21,7 @@ from typing import Any, ClassVar, Dict, List, Optional from onelens_backend_client.models.onelens_domain_utilities_repositories_dynamic_filters_filter_criteria import OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria from onelens_backend_client.models.pagination_params import PaginationParams +from onelens_backend_client.models.sort_criteria import SortCriteria from typing import Optional, Set from typing_extensions import Self @@ -30,8 +31,9 @@ class GetTenantPoliciesWithSettingsRequest(BaseModel): """ # noqa: E501 pagination: Optional[PaginationParams] = Field(default=None, description="Pagination parameters for the request.") filters: List[OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria] = Field(description="Filters to be applied") + sort_criteria: Optional[SortCriteria] = None tenant_id: StrictStr = Field(description="The id of the tenant.") - __properties: ClassVar[List[str]] = ["pagination", "filters", "tenant_id"] + __properties: ClassVar[List[str]] = ["pagination", "filters", "sort_criteria", "tenant_id"] model_config = ConfigDict( populate_by_name=True, @@ -82,6 +84,14 @@ def to_dict(self) -> Dict[str, Any]: if _item: _items.append(_item.to_dict()) _dict['filters'] = _items + # override the default output from pydantic by calling `to_dict()` of sort_criteria + if self.sort_criteria: + _dict['sort_criteria'] = self.sort_criteria.to_dict() + # set to None if sort_criteria (nullable) is None + # and model_fields_set contains the field + if self.sort_criteria is None and "sort_criteria" in self.model_fields_set: + _dict['sort_criteria'] = None + return _dict @classmethod @@ -96,6 +106,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "pagination": PaginationParams.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, "filters": [OnelensDomainUtilitiesRepositoriesDynamicFiltersFilterCriteria.from_dict(_item) for _item in obj["filters"]] if obj.get("filters") is not None else None, + "sort_criteria": SortCriteria.from_dict(obj["sort_criteria"]) if obj.get("sort_criteria") is not None else None, "tenant_id": obj.get("tenant_id") }) return _obj diff --git a/onelens_backend_client/models/get_tenant_policy_by_id_response.py b/onelens_backend_client/models/get_tenant_policy_by_id_response.py index 616d184f..a713ca90 100644 --- a/onelens_backend_client/models/get_tenant_policy_by_id_response.py +++ b/onelens_backend_client/models/get_tenant_policy_by_id_response.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_output import PolicyTemplateDetailsOutput @@ -37,7 +37,7 @@ class GetTenantPolicyByIdResponse(BaseModel): title: StrictStr = Field(description="The title of the policy template.") alias: StrictStr = Field(description="The alias of the policy template.") description: Optional[StrictStr] = Field(default=None, description="The description of the policy template.") - services: List[CreatePolicyTemplateRequestServicesInner] = Field(description="The list of services associated the policy template.") + services: List[ActionTypeFiltersServicesInner] = Field(description="The list of services associated the policy template.") execution_type: PolicyExecutionType = Field(description="The execution type of the policy template.") details: PolicyTemplateDetailsOutput = Field(description="The details of the policy template.") description2: Optional[StrictStr] = Field(default=None, description="The description2 of the policy template.") @@ -118,7 +118,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "title": obj.get("title"), "alias": obj.get("alias"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsOutput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/get_tenant_user_profile_response.py b/onelens_backend_client/models/get_tenant_user_profile_response.py new file mode 100644 index 00000000..1b95a231 --- /dev/null +++ b/onelens_backend_client/models/get_tenant_user_profile_response.py @@ -0,0 +1,231 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.city import City +from onelens_backend_client.models.country import Country +from onelens_backend_client.models.create_tenant_user_request_persona import CreateTenantUserRequestPersona +from onelens_backend_client.models.display_date_format import DisplayDateFormat +from onelens_backend_client.models.display_language import DisplayLanguage +from onelens_backend_client.models.display_time_format import DisplayTimeFormat +from onelens_backend_client.models.email import Email +from onelens_backend_client.models.first_name import FirstName +from onelens_backend_client.models.job_title import JobTitle +from onelens_backend_client.models.last_login import LastLogin +from onelens_backend_client.models.last_name import LastName +from onelens_backend_client.models.manager import Manager +from onelens_backend_client.models.middle_name import MiddleName +from onelens_backend_client.models.mobile_country_code import MobileCountryCode +from onelens_backend_client.models.mobile_number import MobileNumber +from onelens_backend_client.models.preferred_currency import PreferredCurrency +from onelens_backend_client.models.profile_pic_url import ProfilePicUrl +from onelens_backend_client.models.sources import Sources +from onelens_backend_client.models.state import State +from onelens_backend_client.models.timezone import Timezone +from onelens_backend_client.models.user_role import UserRole +from onelens_backend_client.models.user_status import UserStatus +from typing import Optional, Set +from typing_extensions import Self + +class GetTenantUserProfileResponse(BaseModel): + """ + GetTenantUserProfileResponse + """ # noqa: E501 + profile_pic_url: Optional[ProfilePicUrl] = None + last_login: Optional[LastLogin] = None + status: Optional[UserStatus] = Field(default=None, description="Status of the user like ACTIVE, BLOCKED etc.") + first_name: FirstName + middle_name: Optional[MiddleName] = None + last_name: LastName + email: Optional[Email] = None + mobile_country_code: Optional[MobileCountryCode] = None + mobile_number: Optional[MobileNumber] = None + persona: Optional[CreateTenantUserRequestPersona] = None + role: Optional[UserRole] = Field(default=None, description="Role of the user in the tenant") + job_title: Optional[JobTitle] = None + manager: Optional[Manager] = None + city: Optional[City] = None + state: Optional[State] = None + country: Optional[Country] = None + display_language: Optional[DisplayLanguage] = None + preferred_currency: Optional[PreferredCurrency] = None + timezone: Optional[Timezone] = None + display_date_format: Optional[DisplayDateFormat] = None + display_time_format: Optional[DisplayTimeFormat] = None + sources: Optional[Sources] = None + ol_user_id: Optional[Any] = Field(description="Unique onelens identifier for the user") + additional_properties: Dict[str, Any] = {} + __properties: ClassVar[List[str]] = ["profile_pic_url", "last_login", "status", "first_name", "middle_name", "last_name", "email", "mobile_country_code", "mobile_number", "persona", "role", "job_title", "manager", "city", "state", "country", "display_language", "preferred_currency", "timezone", "display_date_format", "display_time_format", "sources", "ol_user_id"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GetTenantUserProfileResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `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, + ) + # override the default output from pydantic by calling `to_dict()` of profile_pic_url + if self.profile_pic_url: + _dict['profile_pic_url'] = self.profile_pic_url.to_dict() + # override the default output from pydantic by calling `to_dict()` of last_login + if self.last_login: + _dict['last_login'] = self.last_login.to_dict() + # override the default output from pydantic by calling `to_dict()` of first_name + if self.first_name: + _dict['first_name'] = self.first_name.to_dict() + # override the default output from pydantic by calling `to_dict()` of middle_name + if self.middle_name: + _dict['middle_name'] = self.middle_name.to_dict() + # override the default output from pydantic by calling `to_dict()` of last_name + if self.last_name: + _dict['last_name'] = self.last_name.to_dict() + # override the default output from pydantic by calling `to_dict()` of email + if self.email: + _dict['email'] = self.email.to_dict() + # override the default output from pydantic by calling `to_dict()` of mobile_country_code + if self.mobile_country_code: + _dict['mobile_country_code'] = self.mobile_country_code.to_dict() + # override the default output from pydantic by calling `to_dict()` of mobile_number + if self.mobile_number: + _dict['mobile_number'] = self.mobile_number.to_dict() + # override the default output from pydantic by calling `to_dict()` of persona + if self.persona: + _dict['persona'] = self.persona.to_dict() + # override the default output from pydantic by calling `to_dict()` of job_title + if self.job_title: + _dict['job_title'] = self.job_title.to_dict() + # override the default output from pydantic by calling `to_dict()` of manager + if self.manager: + _dict['manager'] = self.manager.to_dict() + # override the default output from pydantic by calling `to_dict()` of city + if self.city: + _dict['city'] = self.city.to_dict() + # override the default output from pydantic by calling `to_dict()` of state + if self.state: + _dict['state'] = self.state.to_dict() + # override the default output from pydantic by calling `to_dict()` of country + if self.country: + _dict['country'] = self.country.to_dict() + # override the default output from pydantic by calling `to_dict()` of display_language + if self.display_language: + _dict['display_language'] = self.display_language.to_dict() + # override the default output from pydantic by calling `to_dict()` of preferred_currency + if self.preferred_currency: + _dict['preferred_currency'] = self.preferred_currency.to_dict() + # override the default output from pydantic by calling `to_dict()` of timezone + if self.timezone: + _dict['timezone'] = self.timezone.to_dict() + # override the default output from pydantic by calling `to_dict()` of display_date_format + if self.display_date_format: + _dict['display_date_format'] = self.display_date_format.to_dict() + # override the default output from pydantic by calling `to_dict()` of display_time_format + if self.display_time_format: + _dict['display_time_format'] = self.display_time_format.to_dict() + # override the default output from pydantic by calling `to_dict()` of sources + if self.sources: + _dict['sources'] = self.sources.to_dict() + # 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 + + # set to None if ol_user_id (nullable) is None + # and model_fields_set contains the field + if self.ol_user_id is None and "ol_user_id" in self.model_fields_set: + _dict['ol_user_id'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GetTenantUserProfileResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "profile_pic_url": ProfilePicUrl.from_dict(obj["profile_pic_url"]) if obj.get("profile_pic_url") is not None else None, + "last_login": LastLogin.from_dict(obj["last_login"]) if obj.get("last_login") is not None else None, + "status": obj.get("status"), + "first_name": FirstName.from_dict(obj["first_name"]) if obj.get("first_name") is not None else None, + "middle_name": MiddleName.from_dict(obj["middle_name"]) if obj.get("middle_name") is not None else None, + "last_name": LastName.from_dict(obj["last_name"]) if obj.get("last_name") is not None else None, + "email": Email.from_dict(obj["email"]) if obj.get("email") is not None else None, + "mobile_country_code": MobileCountryCode.from_dict(obj["mobile_country_code"]) if obj.get("mobile_country_code") is not None else None, + "mobile_number": MobileNumber.from_dict(obj["mobile_number"]) if obj.get("mobile_number") is not None else None, + "persona": CreateTenantUserRequestPersona.from_dict(obj["persona"]) if obj.get("persona") is not None else None, + "role": obj.get("role"), + "job_title": JobTitle.from_dict(obj["job_title"]) if obj.get("job_title") is not None else None, + "manager": Manager.from_dict(obj["manager"]) if obj.get("manager") is not None else None, + "city": City.from_dict(obj["city"]) if obj.get("city") is not None else None, + "state": State.from_dict(obj["state"]) if obj.get("state") is not None else None, + "country": Country.from_dict(obj["country"]) if obj.get("country") is not None else None, + "display_language": DisplayLanguage.from_dict(obj["display_language"]) if obj.get("display_language") is not None else None, + "preferred_currency": PreferredCurrency.from_dict(obj["preferred_currency"]) if obj.get("preferred_currency") is not None else None, + "timezone": Timezone.from_dict(obj["timezone"]) if obj.get("timezone") is not None else None, + "display_date_format": DisplayDateFormat.from_dict(obj["display_date_format"]) if obj.get("display_date_format") is not None else None, + "display_time_format": DisplayTimeFormat.from_dict(obj["display_time_format"]) if obj.get("display_time_format") is not None else None, + "sources": Sources.from_dict(obj["sources"]) if obj.get("sources") is not None else None, + "ol_user_id": obj.get("ol_user_id") + }) + # 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/onelens_backend_client/models/password_change_email_request.py b/onelens_backend_client/models/password_change_email_request.py new file mode 100644 index 00000000..db92bc44 --- /dev/null +++ b/onelens_backend_client/models/password_change_email_request.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 import Optional, Set +from typing_extensions import Self + +class PasswordChangeEmailRequest(BaseModel): + """ + PasswordChangeEmailRequest + """ # noqa: E501 + ol_user_id: StrictStr = Field(description="Unique onelens identifier for the user") + tenant_id: StrictStr = Field(description="The unique identifier of the tenant") + __properties: ClassVar[List[str]] = ["ol_user_id", "tenant_id"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordChangeEmailRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 PasswordChangeEmailRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "ol_user_id": obj.get("ol_user_id"), + "tenant_id": obj.get("tenant_id") + }) + return _obj + + diff --git a/onelens_backend_client/models/password_change_email_response.py b/onelens_backend_client/models/password_change_email_response.py new file mode 100644 index 00000000..0087918f --- /dev/null +++ b/onelens_backend_client/models/password_change_email_response.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 import Optional, Set +from typing_extensions import Self + +class PasswordChangeEmailResponse(BaseModel): + """ + PasswordChangeEmailResponse + """ # noqa: E501 + message: StrictStr = Field(description="Message for password change email response") + __properties: ClassVar[List[str]] = ["message"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordChangeEmailResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 PasswordChangeEmailResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "message": obj.get("message") + }) + return _obj + + diff --git a/onelens_backend_client/models/policy_template.py b/onelens_backend_client/models/policy_template.py index 5ef56f24..881c085a 100644 --- a/onelens_backend_client/models/policy_template.py +++ b/onelens_backend_client/models/policy_template.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_output import PolicyTemplateDetailsOutput @@ -37,7 +37,7 @@ class PolicyTemplate(BaseModel): title: StrictStr = Field(description="The title of the policy template.") alias: StrictStr = Field(description="The alias of the policy template.") description: Optional[StrictStr] = Field(default=None, description="The description of the policy template.") - services: List[CreatePolicyTemplateRequestServicesInner] = Field(description="The list of services associated the policy template.") + services: List[ActionTypeFiltersServicesInner] = Field(description="The list of services associated the policy template.") execution_type: PolicyExecutionType = Field(description="The execution type of the policy template.") details: PolicyTemplateDetailsOutput = Field(description="The details of the policy template.") description2: Optional[StrictStr] = Field(default=None, description="The description2 of the policy template.") @@ -117,7 +117,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "title": obj.get("title"), "alias": obj.get("alias"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsOutput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/policy_template_filters.py b/onelens_backend_client/models/policy_template_filters.py index 61be489c..ea75f2cd 100644 --- a/onelens_backend_client/models/policy_template_filters.py +++ b/onelens_backend_client/models/policy_template_filters.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_state import PolicyTemplateState @@ -36,7 +36,7 @@ class PolicyTemplateFilters(BaseModel): states: Optional[List[PolicyTemplateState]] = Field(default=None, description="Filter by state. Default is ACTIVE.") categories: Optional[List[PolicyCategory]] = Field(default=None, description="Filter by type.") providers: Optional[List[Provider]] = Field(default=None, description="Filter by provider.") - services: Optional[List[CreatePolicyTemplateRequestServicesInner]] = Field(default=None, description="Filter by services.") + services: Optional[List[ActionTypeFiltersServicesInner]] = Field(default=None, description="Filter by services.") execution_types: Optional[List[PolicyExecutionType]] = Field(default=None, description="Filter by execution type.") __properties: ClassVar[List[str]] = ["search_query", "parent_ptp_ids", "states", "categories", "providers", "services", "execution_types"] @@ -108,7 +108,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "states": obj.get("states"), "categories": obj.get("categories"), "providers": obj.get("providers"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_types": obj.get("execution_types") }) return _obj diff --git a/onelens_backend_client/models/policy_template_update_fields_mixin.py b/onelens_backend_client/models/policy_template_update_fields_mixin.py index b1648f64..badeef2a 100644 --- a/onelens_backend_client/models/policy_template_update_fields_mixin.py +++ b/onelens_backend_client/models/policy_template_update_fields_mixin.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_input import PolicyTemplateDetailsInput from onelens_backend_client.models.policy_template_recommendation_details_input import PolicyTemplateRecommendationDetailsInput @@ -32,7 +32,7 @@ class PolicyTemplateUpdateFieldsMixin(BaseModel): """ # noqa: E501 title: Optional[StrictStr] = None description: Optional[StrictStr] = None - services: Optional[List[CreatePolicyTemplateRequestServicesInner]] = None + services: Optional[List[ActionTypeFiltersServicesInner]] = None execution_type: Optional[PolicyExecutionType] = None details: Optional[PolicyTemplateDetailsInput] = None description2: Optional[StrictStr] = None @@ -146,7 +146,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "title": obj.get("title"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsInput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/provider_config_input.py b/onelens_backend_client/models/provider_config_input.py index ad8b594e..895b1a3d 100644 --- a/onelens_backend_client/models/provider_config_input.py +++ b/onelens_backend_client/models/provider_config_input.py @@ -20,6 +20,7 @@ from pydantic import BaseModel, ConfigDict, StrictStr from typing import Any, ClassVar, Dict, List, Optional from onelens_backend_client.models.cur_bucket_config import CurBucketConfig +from onelens_backend_client.models.storage_lens_config import StorageLensConfig from typing import Optional, Set from typing_extensions import Self @@ -30,7 +31,8 @@ class ProviderConfigInput(BaseModel): regions: Optional[Dict[str, Any]] = None role_name: Optional[StrictStr] = None cur_bucket_config: Optional[CurBucketConfig] = None - __properties: ClassVar[List[str]] = ["regions", "role_name", "cur_bucket_config"] + storage_lens_config: Optional[StorageLensConfig] = None + __properties: ClassVar[List[str]] = ["regions", "role_name", "cur_bucket_config", "storage_lens_config"] model_config = ConfigDict( populate_by_name=True, @@ -74,6 +76,9 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of cur_bucket_config if self.cur_bucket_config: _dict['cur_bucket_config'] = self.cur_bucket_config.to_dict() + # override the default output from pydantic by calling `to_dict()` of storage_lens_config + if self.storage_lens_config: + _dict['storage_lens_config'] = self.storage_lens_config.to_dict() # set to None if regions (nullable) is None # and model_fields_set contains the field if self.regions is None and "regions" in self.model_fields_set: @@ -89,6 +94,11 @@ def to_dict(self) -> Dict[str, Any]: if self.cur_bucket_config is None and "cur_bucket_config" in self.model_fields_set: _dict['cur_bucket_config'] = None + # set to None if storage_lens_config (nullable) is None + # and model_fields_set contains the field + if self.storage_lens_config is None and "storage_lens_config" in self.model_fields_set: + _dict['storage_lens_config'] = None + return _dict @classmethod @@ -103,7 +113,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "regions": obj.get("regions"), "role_name": obj.get("role_name"), - "cur_bucket_config": CurBucketConfig.from_dict(obj["cur_bucket_config"]) if obj.get("cur_bucket_config") is not None else None + "cur_bucket_config": CurBucketConfig.from_dict(obj["cur_bucket_config"]) if obj.get("cur_bucket_config") is not None else None, + "storage_lens_config": StorageLensConfig.from_dict(obj["storage_lens_config"]) if obj.get("storage_lens_config") is not None else None }) return _obj diff --git a/onelens_backend_client/models/provider_config_output.py b/onelens_backend_client/models/provider_config_output.py index 19ecec68..9baa3cae 100644 --- a/onelens_backend_client/models/provider_config_output.py +++ b/onelens_backend_client/models/provider_config_output.py @@ -20,6 +20,7 @@ from pydantic import BaseModel, ConfigDict, StrictStr from typing import Any, ClassVar, Dict, List, Optional from onelens_backend_client.models.cur_bucket_config import CurBucketConfig +from onelens_backend_client.models.storage_lens_config import StorageLensConfig from typing import Optional, Set from typing_extensions import Self @@ -30,7 +31,8 @@ class ProviderConfigOutput(BaseModel): regions: Optional[Dict[str, Any]] = None role_name: Optional[StrictStr] = None cur_bucket_config: Optional[CurBucketConfig] = None - __properties: ClassVar[List[str]] = ["regions", "role_name", "cur_bucket_config"] + storage_lens_config: Optional[StorageLensConfig] = None + __properties: ClassVar[List[str]] = ["regions", "role_name", "cur_bucket_config", "storage_lens_config"] model_config = ConfigDict( populate_by_name=True, @@ -74,6 +76,9 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of cur_bucket_config if self.cur_bucket_config: _dict['cur_bucket_config'] = self.cur_bucket_config.to_dict() + # override the default output from pydantic by calling `to_dict()` of storage_lens_config + if self.storage_lens_config: + _dict['storage_lens_config'] = self.storage_lens_config.to_dict() # set to None if regions (nullable) is None # and model_fields_set contains the field if self.regions is None and "regions" in self.model_fields_set: @@ -89,6 +94,11 @@ def to_dict(self) -> Dict[str, Any]: if self.cur_bucket_config is None and "cur_bucket_config" in self.model_fields_set: _dict['cur_bucket_config'] = None + # set to None if storage_lens_config (nullable) is None + # and model_fields_set contains the field + if self.storage_lens_config is None and "storage_lens_config" in self.model_fields_set: + _dict['storage_lens_config'] = None + return _dict @classmethod @@ -103,7 +113,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "regions": obj.get("regions"), "role_name": obj.get("role_name"), - "cur_bucket_config": CurBucketConfig.from_dict(obj["cur_bucket_config"]) if obj.get("cur_bucket_config") is not None else None + "cur_bucket_config": CurBucketConfig.from_dict(obj["cur_bucket_config"]) if obj.get("cur_bucket_config") is not None else None, + "storage_lens_config": StorageLensConfig.from_dict(obj["storage_lens_config"]) if obj.get("storage_lens_config") is not None else None }) return _obj diff --git a/onelens_backend_client/models/query_details_derived_variables.py b/onelens_backend_client/models/query_details_derived_variables.py new file mode 100644 index 00000000..0cbb8e44 --- /dev/null +++ b/onelens_backend_client/models/query_details_derived_variables.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 import Optional, Set +from typing_extensions import Self + +class QueryDetailsDerivedVariables(BaseModel): + """ + QueryDetailsDerivedVariables + """ # noqa: E501 + key: StrictStr = Field(description="Key") + value_type: StrictStr = Field(description="Value Type") + source_key: StrictStr = Field(description="Source Key") + __properties: ClassVar[List[str]] = ["key", "value_type", "source_key"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of QueryDetailsDerivedVariables from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 QueryDetailsDerivedVariables 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"), + "value_type": obj.get("value_type"), + "source_key": obj.get("source_key") + }) + return _obj + + diff --git a/onelens_backend_client/models/recommendation_query_details.py b/onelens_backend_client/models/recommendation_query_details.py new file mode 100644 index 00000000..360a0420 --- /dev/null +++ b/onelens_backend_client/models/recommendation_query_details.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.query_details_derived_variables import QueryDetailsDerivedVariables +from typing import Optional, Set +from typing_extensions import Self + +class RecommendationQueryDetails(BaseModel): + """ + RecommendationQueryDetails + """ # noqa: E501 + derived_variables: List[QueryDetailsDerivedVariables] = Field(description="Actual") + query: StrictStr = Field(description="Sql Query to get the recommendation") + __properties: ClassVar[List[str]] = ["derived_variables", "query"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RecommendationQueryDetails from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 derived_variables (list) + _items = [] + if self.derived_variables: + for _item in self.derived_variables: + if _item: + _items.append(_item.to_dict()) + _dict['derived_variables'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RecommendationQueryDetails from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "derived_variables": [QueryDetailsDerivedVariables.from_dict(_item) for _item in obj["derived_variables"]] if obj.get("derived_variables") is not None else None, + "query": obj.get("query") + }) + return _obj + + diff --git a/onelens_backend_client/models/recommendation_unit.py b/onelens_backend_client/models/recommendation_unit.py new file mode 100644 index 00000000..e793d802 --- /dev/null +++ b/onelens_backend_client/models/recommendation_unit.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.effort import Effort +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails +from typing import Optional, Set +from typing_extensions import Self + +class RecommendationUnit(BaseModel): + """ + RecommendationUnit + """ # noqa: E501 + id: StrictStr = Field(description="Recommendation Config ID") + service: StrictStr = Field(description="Service AWS etc.") + action_type_id: Optional[StrictInt] = None + priority: StrictInt = Field(description="Priority") + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + effort: Effort = Field(description="Effort") + query_details: Optional[RecommendationQueryDetails] + __properties: ClassVar[List[str]] = ["id", "service", "action_type_id", "priority", "title", "subtitle", "description", "effort", "query_details"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RecommendationUnit from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 query_details + if self.query_details: + _dict['query_details'] = self.query_details.to_dict() + # set to None if action_type_id (nullable) is None + # and model_fields_set contains the field + if self.action_type_id is None and "action_type_id" in self.model_fields_set: + _dict['action_type_id'] = None + + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + # set to None if query_details (nullable) is None + # and model_fields_set contains the field + if self.query_details is None and "query_details" in self.model_fields_set: + _dict['query_details'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RecommendationUnit 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"), + "service": obj.get("service"), + "action_type_id": obj.get("action_type_id"), + "priority": obj.get("priority"), + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "effort": obj.get("effort"), + "query_details": RecommendationQueryDetails.from_dict(obj["query_details"]) if obj.get("query_details") is not None else None + }) + return _obj + + diff --git a/onelens_backend_client/models/recommendation_unit_filters.py b/onelens_backend_client/models/recommendation_unit_filters.py new file mode 100644 index 00000000..d3e4dd03 --- /dev/null +++ b/onelens_backend_client/models/recommendation_unit_filters.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.effort import Effort +from typing import Optional, Set +from typing_extensions import Self + +class RecommendationUnitFilters(BaseModel): + """ + RecommendationUnitFilters + """ # noqa: E501 + search_query: Optional[StrictStr] = None + ids: Optional[List[StrictStr]] = Field(default=None, description="Filter by recommendation unit id/alias.") + services: Optional[List[StrictStr]] = Field(default=None, description="Filter by Services") + action_type_ids: Optional[List[StrictInt]] = Field(default=None, description="Filter by action type.") + priorities: Optional[List[StrictInt]] = Field(default=None, description="Filter by priorities.") + efforts: Optional[List[Effort]] = Field(default=None, description="Filter by effort.") + __properties: ClassVar[List[str]] = ["search_query", "ids", "services", "action_type_ids", "priorities", "efforts"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RecommendationUnitFilters from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 search_query (nullable) is None + # and model_fields_set contains the field + if self.search_query is None and "search_query" in self.model_fields_set: + _dict['search_query'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RecommendationUnitFilters from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "search_query": obj.get("search_query"), + "ids": obj.get("ids"), + "services": obj.get("services"), + "action_type_ids": obj.get("action_type_ids"), + "priorities": obj.get("priorities"), + "efforts": obj.get("efforts") + }) + return _obj + + diff --git a/onelens_backend_client/models/response_get_tenant_user_profile_response.py b/onelens_backend_client/models/response_get_tenant_user_profile_response.py new file mode 100644 index 00000000..5b9d8932 --- /dev/null +++ b/onelens_backend_client/models/response_get_tenant_user_profile_response.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do 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 onelens_backend_client.models.get_tenant_user_profile_response import GetTenantUserProfileResponse +from typing import Optional, Set +from typing_extensions import Self + +class ResponseGetTenantUserProfileResponse(BaseModel): + """ + ResponseGetTenantUserProfileResponse + """ # noqa: E501 + data: GetTenantUserProfileResponse + message: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["data", "message"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ResponseGetTenantUserProfileResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 data + if self.data: + _dict['data'] = self.data.to_dict() + # set to None if message (nullable) is None + # and model_fields_set contains the field + if self.message is None and "message" in self.model_fields_set: + _dict['message'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ResponseGetTenantUserProfileResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "data": GetTenantUserProfileResponse.from_dict(obj["data"]) if obj.get("data") is not None else None, + "message": obj.get("message") + }) + return _obj + + diff --git a/onelens_backend_client/models/response_password_change_email_response.py b/onelens_backend_client/models/response_password_change_email_response.py new file mode 100644 index 00000000..46a34b8c --- /dev/null +++ b/onelens_backend_client/models/response_password_change_email_response.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do 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 onelens_backend_client.models.password_change_email_response import PasswordChangeEmailResponse +from typing import Optional, Set +from typing_extensions import Self + +class ResponsePasswordChangeEmailResponse(BaseModel): + """ + ResponsePasswordChangeEmailResponse + """ # noqa: E501 + data: PasswordChangeEmailResponse + message: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["data", "message"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ResponsePasswordChangeEmailResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 data + if self.data: + _dict['data'] = self.data.to_dict() + # set to None if message (nullable) is None + # and model_fields_set contains the field + if self.message is None and "message" in self.model_fields_set: + _dict['message'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ResponsePasswordChangeEmailResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "data": PasswordChangeEmailResponse.from_dict(obj["data"]) if obj.get("data") is not None else None, + "message": obj.get("message") + }) + return _obj + + diff --git a/onelens_backend_client/models/service.py b/onelens_backend_client/models/service.py new file mode 100644 index 00000000..197abee6 --- /dev/null +++ b/onelens_backend_client/models/service.py @@ -0,0 +1,134 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +from inspect import getfullargspec +import json +import pprint +import re # noqa: F401 +from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator +from typing import Optional +from onelens_backend_client.models.aws_service import AwsService +from onelens_backend_client.models.gcp_service import GcpService +from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict +from typing_extensions import Literal, Self +from pydantic import Field + +SERVICE_ANY_OF_SCHEMAS = ["AwsService", "GcpService"] + +class Service(BaseModel): + """ + Service AWS etc. + """ + + # data type: AwsService + anyof_schema_1_validator: Optional[AwsService] = None + # data type: GcpService + anyof_schema_2_validator: Optional[GcpService] = None + if TYPE_CHECKING: + actual_instance: Optional[Union[AwsService, GcpService]] = None + else: + actual_instance: Any = None + any_of_schemas: Set[str] = { "AwsService", "GcpService" } + + model_config = { + "validate_assignment": True, + "protected_namespaces": (), + } + + 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_anyof(cls, v): + instance = Service.model_construct() + error_messages = [] + # validate data type: AwsService + if not isinstance(v, AwsService): + error_messages.append(f"Error! Input type `{type(v)}` is not `AwsService`") + else: + return v + + # validate data type: GcpService + if not isinstance(v, GcpService): + error_messages.append(f"Error! Input type `{type(v)}` is not `GcpService`") + else: + return v + + if error_messages: + # no match + raise ValueError("No match found when setting the actual_instance in Service with anyOf schemas: AwsService, GcpService. Details: " + ", ".join(error_messages)) + else: + return v + + @classmethod + def from_dict(cls, obj: 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 = [] + # anyof_schema_1_validator: Optional[AwsService] = None + try: + instance.actual_instance = AwsService.from_json(json_str) + return instance + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # anyof_schema_2_validator: Optional[GcpService] = None + try: + instance.actual_instance = GcpService.from_json(json_str) + return instance + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + + if error_messages: + # no match + raise ValueError("No match found when deserializing the JSON string into Service with anyOf schemas: AwsService, GcpService. 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], AwsService, GcpService]]: + """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: + 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/onelens_backend_client/models/storage_lens_config.py b/onelens_backend_client/models/storage_lens_config.py new file mode 100644 index 00000000..cb9cccc7 --- /dev/null +++ b/onelens_backend_client/models/storage_lens_config.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do 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 + +class StorageLensConfig(BaseModel): + """ + StorageLensConfig + """ # noqa: E501 + name: Optional[StrictStr] = None + region: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "region"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of StorageLensConfig from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 name (nullable) is None + # and model_fields_set contains the field + if self.name is None and "name" in self.model_fields_set: + _dict['name'] = None + + # set to None if region (nullable) is None + # and model_fields_set contains the field + if self.region is None and "region" in self.model_fields_set: + _dict['region'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of StorageLensConfig 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"), + "region": obj.get("region") + }) + return _obj + + diff --git a/onelens_backend_client/models/tenant_policy.py b/onelens_backend_client/models/tenant_policy.py index 55340efd..8dac623b 100644 --- a/onelens_backend_client/models/tenant_policy.py +++ b/onelens_backend_client/models/tenant_policy.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_output import PolicyTemplateDetailsOutput @@ -37,7 +37,7 @@ class TenantPolicy(BaseModel): title: StrictStr = Field(description="The title of the policy template.") alias: StrictStr = Field(description="The alias of the policy template.") description: Optional[StrictStr] = Field(default=None, description="The description of the policy template.") - services: List[CreatePolicyTemplateRequestServicesInner] = Field(description="The list of services associated the policy template.") + services: List[ActionTypeFiltersServicesInner] = Field(description="The list of services associated the policy template.") execution_type: PolicyExecutionType = Field(description="The execution type of the policy template.") details: PolicyTemplateDetailsOutput = Field(description="The details of the policy template.") description2: Optional[StrictStr] = Field(default=None, description="The description2 of the policy template.") @@ -118,7 +118,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "title": obj.get("title"), "alias": obj.get("alias"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsOutput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/tenant_policy_filters.py b/onelens_backend_client/models/tenant_policy_filters.py index 38cfcebd..5c3d193a 100644 --- a/onelens_backend_client/models/tenant_policy_filters.py +++ b/onelens_backend_client/models/tenant_policy_filters.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.provider import Provider @@ -34,7 +34,7 @@ class TenantPolicyFilters(BaseModel): parent_ptp_ids: Optional[List[StrictStr]] = Field(default=None, description="Filter by parent policy template pack id.") categories: Optional[List[PolicyCategory]] = Field(default=None, description="Filter by type.") providers: Optional[List[Provider]] = Field(default=None, description="Filter by provider.") - services: Optional[List[CreatePolicyTemplateRequestServicesInner]] = Field(default=None, description="Filter by services.") + services: Optional[List[ActionTypeFiltersServicesInner]] = Field(default=None, description="Filter by services.") execution_types: Optional[List[PolicyExecutionType]] = Field(default=None, description="Filter by execution type.") __properties: ClassVar[List[str]] = ["search_query", "parent_ptp_ids", "categories", "providers", "services", "execution_types"] @@ -105,7 +105,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "parent_ptp_ids": obj.get("parent_ptp_ids"), "categories": obj.get("categories"), "providers": obj.get("providers"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_types": obj.get("execution_types") }) return _obj diff --git a/onelens_backend_client/models/tenant_provider_attributes.py b/onelens_backend_client/models/tenant_provider_attributes.py index 7c0ceb4b..82011f0a 100644 --- a/onelens_backend_client/models/tenant_provider_attributes.py +++ b/onelens_backend_client/models/tenant_provider_attributes.py @@ -28,6 +28,7 @@ class TenantProviderAttributes(str, Enum): """ ROLE_ARN = 'role_arn' DB_CONNECTION_STRING = 'db_connection_string' + STORAGE_LENS_CONFIGURATION = 'storage_lens_configuration' @classmethod def from_json(cls, json_str: str) -> Self: diff --git a/onelens_backend_client/models/tenant_verify_request_with_user.py b/onelens_backend_client/models/tenant_verify_request_with_user.py index 31d15526..6c134633 100644 --- a/onelens_backend_client/models/tenant_verify_request_with_user.py +++ b/onelens_backend_client/models/tenant_verify_request_with_user.py @@ -18,7 +18,8 @@ import json from pydantic import BaseModel, ConfigDict, Field, StrictStr -from typing import Any, ClassVar, Dict, List +from typing import Any, ClassVar, Dict, List, Optional +from onelens_backend_client.models.storage_lens_config import StorageLensConfig from typing import Optional, Set from typing_extensions import Self @@ -29,8 +30,9 @@ class TenantVerifyRequestWithUser(BaseModel): role_name: StrictStr = Field(description="Role name of the tenant") tenant_id: StrictStr = Field(description="Tenant ID") tenant_provider_id: StrictStr = Field(description="Tenant Provider ID") + storage_lens_config: Optional[StorageLensConfig] = None user_id: StrictStr = Field(description="List of users") - __properties: ClassVar[List[str]] = ["role_name", "tenant_id", "tenant_provider_id", "user_id"] + __properties: ClassVar[List[str]] = ["role_name", "tenant_id", "tenant_provider_id", "storage_lens_config", "user_id"] model_config = ConfigDict( populate_by_name=True, @@ -71,6 +73,14 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) + # override the default output from pydantic by calling `to_dict()` of storage_lens_config + if self.storage_lens_config: + _dict['storage_lens_config'] = self.storage_lens_config.to_dict() + # set to None if storage_lens_config (nullable) is None + # and model_fields_set contains the field + if self.storage_lens_config is None and "storage_lens_config" in self.model_fields_set: + _dict['storage_lens_config'] = None + return _dict @classmethod @@ -86,6 +96,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "role_name": obj.get("role_name"), "tenant_id": obj.get("tenant_id"), "tenant_provider_id": obj.get("tenant_provider_id"), + "storage_lens_config": StorageLensConfig.from_dict(obj["storage_lens_config"]) if obj.get("storage_lens_config") is not None else None, "user_id": obj.get("user_id") }) return _obj diff --git a/onelens_backend_client/models/update_action_type_request.py b/onelens_backend_client/models/update_action_type_request.py new file mode 100644 index 00000000..5eab8f64 --- /dev/null +++ b/onelens_backend_client/models/update_action_type_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.service import Service +from typing import Optional, Set +from typing_extensions import Self + +class UpdateActionTypeRequest(BaseModel): + """ + UpdateActionTypeRequest + """ # noqa: E501 + service: Service + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + id: StrictInt = Field(description="Action Type ID") + __properties: ClassVar[List[str]] = ["service", "title", "subtitle", "description", "id"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UpdateActionTypeRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 service + if self.service: + _dict['service'] = self.service.to_dict() + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UpdateActionTypeRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "service": Service.from_dict(obj["service"]) if obj.get("service") is not None else None, + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "id": obj.get("id") + }) + return _obj + + diff --git a/onelens_backend_client/models/update_action_type_response.py b/onelens_backend_client/models/update_action_type_response.py new file mode 100644 index 00000000..cbade55f --- /dev/null +++ b/onelens_backend_client/models/update_action_type_response.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.service import Service +from typing import Optional, Set +from typing_extensions import Self + +class UpdateActionTypeResponse(BaseModel): + """ + UpdateActionTypeResponse + """ # noqa: E501 + service: Service + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + id: StrictInt = Field(description="Action Type ID") + __properties: ClassVar[List[str]] = ["service", "title", "subtitle", "description", "id"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UpdateActionTypeResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 service + if self.service: + _dict['service'] = self.service.to_dict() + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UpdateActionTypeResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "service": Service.from_dict(obj["service"]) if obj.get("service") is not None else None, + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "id": obj.get("id") + }) + return _obj + + diff --git a/onelens_backend_client/models/update_policy_template_request.py b/onelens_backend_client/models/update_policy_template_request.py index d407e487..fac3eb12 100644 --- a/onelens_backend_client/models/update_policy_template_request.py +++ b/onelens_backend_client/models/update_policy_template_request.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_input import PolicyTemplateDetailsInput from onelens_backend_client.models.policy_template_recommendation_details_input import PolicyTemplateRecommendationDetailsInput @@ -33,7 +33,7 @@ class UpdatePolicyTemplateRequest(BaseModel): force_update: Optional[StrictBool] = Field(default=False, description="Force update (TRUE/FALSE), default: FALSE") title: Optional[StrictStr] = None description: Optional[StrictStr] = None - services: Optional[List[CreatePolicyTemplateRequestServicesInner]] = None + services: Optional[List[ActionTypeFiltersServicesInner]] = None execution_type: Optional[PolicyExecutionType] = None details: Optional[PolicyTemplateDetailsInput] = None description2: Optional[StrictStr] = None @@ -149,7 +149,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "force_update": obj.get("force_update") if obj.get("force_update") is not None else False, "title": obj.get("title"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsInput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/update_policy_template_response.py b/onelens_backend_client/models/update_policy_template_response.py index bd7584f0..275e86d7 100644 --- a/onelens_backend_client/models/update_policy_template_response.py +++ b/onelens_backend_client/models/update_policy_template_response.py @@ -19,7 +19,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from onelens_backend_client.models.create_policy_template_request_services_inner import CreatePolicyTemplateRequestServicesInner +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner from onelens_backend_client.models.policy_category import PolicyCategory from onelens_backend_client.models.policy_execution_type import PolicyExecutionType from onelens_backend_client.models.policy_template_details_output import PolicyTemplateDetailsOutput @@ -37,7 +37,7 @@ class UpdatePolicyTemplateResponse(BaseModel): title: StrictStr = Field(description="The title of the policy template.") alias: StrictStr = Field(description="The alias of the policy template.") description: Optional[StrictStr] = Field(default=None, description="The description of the policy template.") - services: List[CreatePolicyTemplateRequestServicesInner] = Field(description="The list of services associated the policy template.") + services: List[ActionTypeFiltersServicesInner] = Field(description="The list of services associated the policy template.") execution_type: PolicyExecutionType = Field(description="The execution type of the policy template.") details: PolicyTemplateDetailsOutput = Field(description="The details of the policy template.") description2: Optional[StrictStr] = Field(default=None, description="The description2 of the policy template.") @@ -117,7 +117,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "title": obj.get("title"), "alias": obj.get("alias"), "description": obj.get("description"), - "services": [CreatePolicyTemplateRequestServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, + "services": [ActionTypeFiltersServicesInner.from_dict(_item) for _item in obj["services"]] if obj.get("services") is not None else None, "execution_type": obj.get("execution_type"), "details": PolicyTemplateDetailsOutput.from_dict(obj["details"]) if obj.get("details") is not None else None, "description2": obj.get("description2"), diff --git a/onelens_backend_client/models/update_recommendation_unit_request.py b/onelens_backend_client/models/update_recommendation_unit_request.py new file mode 100644 index 00000000..0d069048 --- /dev/null +++ b/onelens_backend_client/models/update_recommendation_unit_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.effort import Effort +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails +from typing import Optional, Set +from typing_extensions import Self + +class UpdateRecommendationUnitRequest(BaseModel): + """ + UpdateRecommendationUnitRequest + """ # noqa: E501 + id: StrictStr = Field(description="Recommendation Config ID") + service: StrictStr = Field(description="Service AWS etc.") + action_type_id: Optional[StrictInt] = None + priority: StrictInt = Field(description="Priority") + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + effort: Effort = Field(description="Effort") + query_details: Optional[RecommendationQueryDetails] + __properties: ClassVar[List[str]] = ["id", "service", "action_type_id", "priority", "title", "subtitle", "description", "effort", "query_details"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UpdateRecommendationUnitRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 query_details + if self.query_details: + _dict['query_details'] = self.query_details.to_dict() + # set to None if action_type_id (nullable) is None + # and model_fields_set contains the field + if self.action_type_id is None and "action_type_id" in self.model_fields_set: + _dict['action_type_id'] = None + + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + # set to None if query_details (nullable) is None + # and model_fields_set contains the field + if self.query_details is None and "query_details" in self.model_fields_set: + _dict['query_details'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UpdateRecommendationUnitRequest 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"), + "service": obj.get("service"), + "action_type_id": obj.get("action_type_id"), + "priority": obj.get("priority"), + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "effort": obj.get("effort"), + "query_details": RecommendationQueryDetails.from_dict(obj["query_details"]) if obj.get("query_details") is not None else None + }) + return _obj + + diff --git a/onelens_backend_client/models/update_recommendation_unit_response.py b/onelens_backend_client/models/update_recommendation_unit_response.py new file mode 100644 index 00000000..15472165 --- /dev/null +++ b/onelens_backend_client/models/update_recommendation_unit_response.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not 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 onelens_backend_client.models.effort import Effort +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails +from typing import Optional, Set +from typing_extensions import Self + +class UpdateRecommendationUnitResponse(BaseModel): + """ + UpdateRecommendationUnitResponse + """ # noqa: E501 + id: StrictStr = Field(description="Recommendation Config ID") + service: StrictStr = Field(description="Service AWS etc.") + action_type_id: Optional[StrictInt] = None + priority: StrictInt = Field(description="Priority") + title: StrictStr = Field(description="Title") + subtitle: Optional[StrictStr] = None + description: StrictStr = Field(description="Description") + effort: Effort = Field(description="Effort") + query_details: Optional[RecommendationQueryDetails] + __properties: ClassVar[List[str]] = ["id", "service", "action_type_id", "priority", "title", "subtitle", "description", "effort", "query_details"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UpdateRecommendationUnitResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other 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 query_details + if self.query_details: + _dict['query_details'] = self.query_details.to_dict() + # set to None if action_type_id (nullable) is None + # and model_fields_set contains the field + if self.action_type_id is None and "action_type_id" in self.model_fields_set: + _dict['action_type_id'] = None + + # set to None if subtitle (nullable) is None + # and model_fields_set contains the field + if self.subtitle is None and "subtitle" in self.model_fields_set: + _dict['subtitle'] = None + + # set to None if query_details (nullable) is None + # and model_fields_set contains the field + if self.query_details is None and "query_details" in self.model_fields_set: + _dict['query_details'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UpdateRecommendationUnitResponse 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"), + "service": obj.get("service"), + "action_type_id": obj.get("action_type_id"), + "priority": obj.get("priority"), + "title": obj.get("title"), + "subtitle": obj.get("subtitle"), + "description": obj.get("description"), + "effort": obj.get("effort"), + "query_details": RecommendationQueryDetails.from_dict(obj["query_details"]) if obj.get("query_details") is not None else None + }) + return _obj + + diff --git a/test/test_action_type.py b/test/test_action_type.py new file mode 100644 index 00000000..27cd7bde --- /dev/null +++ b/test/test_action_type.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.action_type import ActionType + +class TestActionType(unittest.TestCase): + """ActionType unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ActionType: + """Test ActionType + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ActionType` + """ + model = ActionType() + if include_optional: + return ActionType( + service = None, + title = '', + subtitle = '', + description = '', + id = 56 + ) + else: + return ActionType( + service = None, + title = '', + description = '', + id = 56, + ) + """ + + def testActionType(self): + """Test ActionType""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_action_type_filters.py b/test/test_action_type_filters.py new file mode 100644 index 00000000..a51a2c6c --- /dev/null +++ b/test/test_action_type_filters.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.action_type_filters import ActionTypeFilters + +class TestActionTypeFilters(unittest.TestCase): + """ActionTypeFilters unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ActionTypeFilters: + """Test ActionTypeFilters + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ActionTypeFilters` + """ + model = ActionTypeFilters() + if include_optional: + return ActionTypeFilters( + search_query = '', + ids = [ + 56 + ], + services = [ + null + ] + ) + else: + return ActionTypeFilters( + ) + """ + + def testActionTypeFilters(self): + """Test ActionTypeFilters""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_action_type_filters_services_inner.py b/test/test_action_type_filters_services_inner.py new file mode 100644 index 00000000..488d6eab --- /dev/null +++ b/test/test_action_type_filters_services_inner.py @@ -0,0 +1,50 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.action_type_filters_services_inner import ActionTypeFiltersServicesInner + +class TestActionTypeFiltersServicesInner(unittest.TestCase): + """ActionTypeFiltersServicesInner unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ActionTypeFiltersServicesInner: + """Test ActionTypeFiltersServicesInner + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ActionTypeFiltersServicesInner` + """ + model = ActionTypeFiltersServicesInner() + if include_optional: + return ActionTypeFiltersServicesInner( + ) + else: + return ActionTypeFiltersServicesInner( + ) + """ + + def testActionTypeFiltersServicesInner(self): + """Test ActionTypeFiltersServicesInner""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_create_action_type_request.py b/test/test_create_action_type_request.py new file mode 100644 index 00000000..35d10b82 --- /dev/null +++ b/test/test_create_action_type_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.create_action_type_request import CreateActionTypeRequest + +class TestCreateActionTypeRequest(unittest.TestCase): + """CreateActionTypeRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CreateActionTypeRequest: + """Test CreateActionTypeRequest + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CreateActionTypeRequest` + """ + model = CreateActionTypeRequest() + if include_optional: + return CreateActionTypeRequest( + service = None, + title = '', + subtitle = '', + description = '' + ) + else: + return CreateActionTypeRequest( + service = None, + title = '', + description = '', + ) + """ + + def testCreateActionTypeRequest(self): + """Test CreateActionTypeRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_create_action_type_response.py b/test/test_create_action_type_response.py new file mode 100644 index 00000000..b1d9e2c2 --- /dev/null +++ b/test/test_create_action_type_response.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.create_action_type_response import CreateActionTypeResponse + +class TestCreateActionTypeResponse(unittest.TestCase): + """CreateActionTypeResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CreateActionTypeResponse: + """Test CreateActionTypeResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CreateActionTypeResponse` + """ + model = CreateActionTypeResponse() + if include_optional: + return CreateActionTypeResponse( + service = None, + title = '', + subtitle = '', + description = '', + id = 56 + ) + else: + return CreateActionTypeResponse( + service = None, + title = '', + description = '', + id = 56, + ) + """ + + def testCreateActionTypeResponse(self): + """Test CreateActionTypeResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_create_recommendation_unit_request.py b/test/test_create_recommendation_unit_request.py new file mode 100644 index 00000000..b034b662 --- /dev/null +++ b/test/test_create_recommendation_unit_request.py @@ -0,0 +1,80 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.create_recommendation_unit_request import CreateRecommendationUnitRequest + +class TestCreateRecommendationUnitRequest(unittest.TestCase): + """CreateRecommendationUnitRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CreateRecommendationUnitRequest: + """Test CreateRecommendationUnitRequest + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CreateRecommendationUnitRequest` + """ + model = CreateRecommendationUnitRequest() + if include_optional: + return CreateRecommendationUnitRequest( + id = '', + service = '', + action_type_id = 56, + priority = 56, + title = '', + subtitle = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ) + ) + else: + return CreateRecommendationUnitRequest( + id = '', + service = '', + priority = 56, + title = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ), + ) + """ + + def testCreateRecommendationUnitRequest(self): + """Test CreateRecommendationUnitRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_create_recommendation_unit_response.py b/test/test_create_recommendation_unit_response.py new file mode 100644 index 00000000..9ebe1877 --- /dev/null +++ b/test/test_create_recommendation_unit_response.py @@ -0,0 +1,80 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.create_recommendation_unit_response import CreateRecommendationUnitResponse + +class TestCreateRecommendationUnitResponse(unittest.TestCase): + """CreateRecommendationUnitResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CreateRecommendationUnitResponse: + """Test CreateRecommendationUnitResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CreateRecommendationUnitResponse` + """ + model = CreateRecommendationUnitResponse() + if include_optional: + return CreateRecommendationUnitResponse( + id = '', + service = '', + action_type_id = 56, + priority = 56, + title = '', + subtitle = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ) + ) + else: + return CreateRecommendationUnitResponse( + id = '', + service = '', + priority = 56, + title = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ), + ) + """ + + def testCreateRecommendationUnitResponse(self): + """Test CreateRecommendationUnitResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_get_action_type_request.py b/test/test_get_action_type_request.py new file mode 100644 index 00000000..9c0d4ecc --- /dev/null +++ b/test/test_get_action_type_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.get_action_type_request import GetActionTypeRequest + +class TestGetActionTypeRequest(unittest.TestCase): + """GetActionTypeRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GetActionTypeRequest: + """Test GetActionTypeRequest + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GetActionTypeRequest` + """ + model = GetActionTypeRequest() + if include_optional: + return GetActionTypeRequest( + pagination = onelens_backend_client.models.pagination_params.PaginationParams( + page = 56, + page_size = 56, ), + filters = onelens_backend_client.models.action_type_filters.ActionTypeFilters( + search_query = '', + ids = [ + 56 + ], + services = [ + null + ], ) + ) + else: + return GetActionTypeRequest( + ) + """ + + def testGetActionTypeRequest(self): + """Test GetActionTypeRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_get_action_type_response.py b/test/test_get_action_type_response.py new file mode 100644 index 00000000..400f4ffb --- /dev/null +++ b/test/test_get_action_type_response.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.get_action_type_response import GetActionTypeResponse + +class TestGetActionTypeResponse(unittest.TestCase): + """GetActionTypeResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GetActionTypeResponse: + """Test GetActionTypeResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GetActionTypeResponse` + """ + model = GetActionTypeResponse() + if include_optional: + return GetActionTypeResponse( + action_types = [ + onelens_backend_client.models.action_type.ActionType( + service = null, + title = '', + subtitle = '', + description = '', + id = 56, ) + ], + pagination = onelens_backend_client.models.pagination_fields.PaginationFields( + total_items = 56, + total_pages = 56, + current_page = 56, + page_size = 56, ) + ) + else: + return GetActionTypeResponse( + action_types = [ + onelens_backend_client.models.action_type.ActionType( + service = null, + title = '', + subtitle = '', + description = '', + id = 56, ) + ], + pagination = onelens_backend_client.models.pagination_fields.PaginationFields( + total_items = 56, + total_pages = 56, + current_page = 56, + page_size = 56, ), + ) + """ + + def testGetActionTypeResponse(self): + """Test GetActionTypeResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_get_recommendation_unit_request.py b/test/test_get_recommendation_unit_request.py new file mode 100644 index 00000000..4732e513 --- /dev/null +++ b/test/test_get_recommendation_unit_request.py @@ -0,0 +1,70 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.get_recommendation_unit_request import GetRecommendationUnitRequest + +class TestGetRecommendationUnitRequest(unittest.TestCase): + """GetRecommendationUnitRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GetRecommendationUnitRequest: + """Test GetRecommendationUnitRequest + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GetRecommendationUnitRequest` + """ + model = GetRecommendationUnitRequest() + if include_optional: + return GetRecommendationUnitRequest( + pagination = onelens_backend_client.models.pagination_params.PaginationParams( + page = 56, + page_size = 56, ), + filters = onelens_backend_client.models.recommendation_unit_filters.RecommendationUnitFilters( + search_query = '', + ids = [ + '' + ], + services = [ + '' + ], + action_type_ids = [ + 56 + ], + priorities = [ + 56 + ], + efforts = [ + 'Easy' + ], ) + ) + else: + return GetRecommendationUnitRequest( + ) + """ + + def testGetRecommendationUnitRequest(self): + """Test GetRecommendationUnitRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_get_tenant_user_profile_response.py b/test/test_get_tenant_user_profile_response.py new file mode 100644 index 00000000..54ec1479 --- /dev/null +++ b/test/test_get_tenant_user_profile_response.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.get_tenant_user_profile_response import GetTenantUserProfileResponse + +class TestGetTenantUserProfileResponse(unittest.TestCase): + """GetTenantUserProfileResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GetTenantUserProfileResponse: + """Test GetTenantUserProfileResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GetTenantUserProfileResponse` + """ + model = GetTenantUserProfileResponse() + if include_optional: + return GetTenantUserProfileResponse( + profile_pic_url = None, + last_login = None, + status = 'ACTIVE', + first_name = None, + middle_name = None, + last_name = None, + email = None, + mobile_country_code = None, + mobile_number = None, + persona = None, + role = 'ADMIN', + job_title = None, + manager = None, + city = None, + state = None, + country = None, + display_language = None, + preferred_currency = None, + timezone = None, + display_date_format = None, + display_time_format = None, + sources = None, + ol_user_id = None + ) + else: + return GetTenantUserProfileResponse( + first_name = None, + last_name = None, + ol_user_id = None, + ) + """ + + def testGetTenantUserProfileResponse(self): + """Test GetTenantUserProfileResponse""" + # inst_req_only = self.make_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_change_email_request.py b/test/test_password_change_email_request.py new file mode 100644 index 00000000..30b39e54 --- /dev/null +++ b/test/test_password_change_email_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.password_change_email_request import PasswordChangeEmailRequest + +class TestPasswordChangeEmailRequest(unittest.TestCase): + """PasswordChangeEmailRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordChangeEmailRequest: + """Test PasswordChangeEmailRequest + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordChangeEmailRequest` + """ + model = PasswordChangeEmailRequest() + if include_optional: + return PasswordChangeEmailRequest( + ol_user_id = '', + tenant_id = '' + ) + else: + return PasswordChangeEmailRequest( + ol_user_id = '', + tenant_id = '', + ) + """ + + def testPasswordChangeEmailRequest(self): + """Test PasswordChangeEmailRequest""" + # inst_req_only = self.make_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_change_email_response.py b/test/test_password_change_email_response.py new file mode 100644 index 00000000..90ed7c20 --- /dev/null +++ b/test/test_password_change_email_response.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.password_change_email_response import PasswordChangeEmailResponse + +class TestPasswordChangeEmailResponse(unittest.TestCase): + """PasswordChangeEmailResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordChangeEmailResponse: + """Test PasswordChangeEmailResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordChangeEmailResponse` + """ + model = PasswordChangeEmailResponse() + if include_optional: + return PasswordChangeEmailResponse( + message = '' + ) + else: + return PasswordChangeEmailResponse( + message = '', + ) + """ + + def testPasswordChangeEmailResponse(self): + """Test PasswordChangeEmailResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_query_details_derived_variables.py b/test/test_query_details_derived_variables.py new file mode 100644 index 00000000..8c4ed4b7 --- /dev/null +++ b/test/test_query_details_derived_variables.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.query_details_derived_variables import QueryDetailsDerivedVariables + +class TestQueryDetailsDerivedVariables(unittest.TestCase): + """QueryDetailsDerivedVariables unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> QueryDetailsDerivedVariables: + """Test QueryDetailsDerivedVariables + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `QueryDetailsDerivedVariables` + """ + model = QueryDetailsDerivedVariables() + if include_optional: + return QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '' + ) + else: + return QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', + ) + """ + + def testQueryDetailsDerivedVariables(self): + """Test QueryDetailsDerivedVariables""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_recommendation_query_details.py b/test/test_recommendation_query_details.py new file mode 100644 index 00000000..64f2e6c4 --- /dev/null +++ b/test/test_recommendation_query_details.py @@ -0,0 +1,64 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.recommendation_query_details import RecommendationQueryDetails + +class TestRecommendationQueryDetails(unittest.TestCase): + """RecommendationQueryDetails unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RecommendationQueryDetails: + """Test RecommendationQueryDetails + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RecommendationQueryDetails` + """ + model = RecommendationQueryDetails() + if include_optional: + return RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '' + ) + else: + return RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', + ) + """ + + def testRecommendationQueryDetails(self): + """Test RecommendationQueryDetails""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_recommendation_unit.py b/test/test_recommendation_unit.py new file mode 100644 index 00000000..4c66f5a9 --- /dev/null +++ b/test/test_recommendation_unit.py @@ -0,0 +1,80 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.recommendation_unit import RecommendationUnit + +class TestRecommendationUnit(unittest.TestCase): + """RecommendationUnit unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RecommendationUnit: + """Test RecommendationUnit + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RecommendationUnit` + """ + model = RecommendationUnit() + if include_optional: + return RecommendationUnit( + id = '', + service = '', + action_type_id = 56, + priority = 56, + title = '', + subtitle = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ) + ) + else: + return RecommendationUnit( + id = '', + service = '', + priority = 56, + title = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ), + ) + """ + + def testRecommendationUnit(self): + """Test RecommendationUnit""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_recommendation_unit_filters.py b/test/test_recommendation_unit_filters.py new file mode 100644 index 00000000..8c026b9e --- /dev/null +++ b/test/test_recommendation_unit_filters.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.recommendation_unit_filters import RecommendationUnitFilters + +class TestRecommendationUnitFilters(unittest.TestCase): + """RecommendationUnitFilters unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RecommendationUnitFilters: + """Test RecommendationUnitFilters + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RecommendationUnitFilters` + """ + model = RecommendationUnitFilters() + if include_optional: + return RecommendationUnitFilters( + search_query = '', + ids = [ + '' + ], + services = [ + '' + ], + action_type_ids = [ + 56 + ], + priorities = [ + 56 + ], + efforts = [ + 'Easy' + ] + ) + else: + return RecommendationUnitFilters( + ) + """ + + def testRecommendationUnitFilters(self): + """Test RecommendationUnitFilters""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_recommendation_unit_service_api.py b/test/test_recommendation_unit_service_api.py new file mode 100644 index 00000000..1cb72c62 --- /dev/null +++ b/test/test_recommendation_unit_service_api.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.api.recommendation_unit_service_api import RecommendationUnitServiceApi + + +class TestRecommendationUnitServiceApi(unittest.TestCase): + """RecommendationUnitServiceApi unit test stubs""" + + def setUp(self) -> None: + self.api = RecommendationUnitServiceApi() + + def tearDown(self) -> None: + pass + + def test_create_recommendation_unit(self) -> None: + """Test case for create_recommendation_unit + + Create recommendation unit + """ + pass + + def test_get_recommendation_unit_by_id(self) -> None: + """Test case for get_recommendation_unit_by_id + + Retrieves Recommendation unit ID. + """ + pass + + def test_get_recommendation_units(self) -> None: + """Test case for get_recommendation_units + + Retrieves all recommendation units with filters + """ + pass + + def test_update_recommendation_unit(self) -> None: + """Test case for update_recommendation_unit + + Update recommendation unit + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_response_get_tenant_user_profile_response.py b/test/test_response_get_tenant_user_profile_response.py new file mode 100644 index 00000000..2566c4f4 --- /dev/null +++ b/test/test_response_get_tenant_user_profile_response.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.response_get_tenant_user_profile_response import ResponseGetTenantUserProfileResponse + +class TestResponseGetTenantUserProfileResponse(unittest.TestCase): + """ResponseGetTenantUserProfileResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ResponseGetTenantUserProfileResponse: + """Test ResponseGetTenantUserProfileResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ResponseGetTenantUserProfileResponse` + """ + model = ResponseGetTenantUserProfileResponse() + if include_optional: + return ResponseGetTenantUserProfileResponse( + data = { + 'key' : null + }, + message = '' + ) + else: + return ResponseGetTenantUserProfileResponse( + data = { + 'key' : null + }, + ) + """ + + def testResponseGetTenantUserProfileResponse(self): + """Test ResponseGetTenantUserProfileResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_response_password_change_email_response.py b/test/test_response_password_change_email_response.py new file mode 100644 index 00000000..03e24134 --- /dev/null +++ b/test/test_response_password_change_email_response.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.response_password_change_email_response import ResponsePasswordChangeEmailResponse + +class TestResponsePasswordChangeEmailResponse(unittest.TestCase): + """ResponsePasswordChangeEmailResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ResponsePasswordChangeEmailResponse: + """Test ResponsePasswordChangeEmailResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ResponsePasswordChangeEmailResponse` + """ + model = ResponsePasswordChangeEmailResponse() + if include_optional: + return ResponsePasswordChangeEmailResponse( + data = onelens_backend_client.models.password_change_email_response.PasswordChangeEmailResponse( + message = '', ), + message = '' + ) + else: + return ResponsePasswordChangeEmailResponse( + data = onelens_backend_client.models.password_change_email_response.PasswordChangeEmailResponse( + message = '', ), + ) + """ + + def testResponsePasswordChangeEmailResponse(self): + """Test ResponsePasswordChangeEmailResponse""" + # inst_req_only = self.make_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.py b/test/test_service.py new file mode 100644 index 00000000..ca6bf222 --- /dev/null +++ b/test/test_service.py @@ -0,0 +1,50 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.service import Service + +class TestService(unittest.TestCase): + """Service unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Service: + """Test Service + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Service` + """ + model = Service() + if include_optional: + return Service( + ) + else: + return Service( + ) + """ + + def testService(self): + """Test Service""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_storage_lens_config.py b/test/test_storage_lens_config.py new file mode 100644 index 00000000..121c0ca3 --- /dev/null +++ b/test/test_storage_lens_config.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.storage_lens_config import StorageLensConfig + +class TestStorageLensConfig(unittest.TestCase): + """StorageLensConfig unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> StorageLensConfig: + """Test StorageLensConfig + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `StorageLensConfig` + """ + model = StorageLensConfig() + if include_optional: + return StorageLensConfig( + name = '', + region = '' + ) + else: + return StorageLensConfig( + ) + """ + + def testStorageLensConfig(self): + """Test StorageLensConfig""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_update_action_type_request.py b/test/test_update_action_type_request.py new file mode 100644 index 00000000..1db906b0 --- /dev/null +++ b/test/test_update_action_type_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.update_action_type_request import UpdateActionTypeRequest + +class TestUpdateActionTypeRequest(unittest.TestCase): + """UpdateActionTypeRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UpdateActionTypeRequest: + """Test UpdateActionTypeRequest + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UpdateActionTypeRequest` + """ + model = UpdateActionTypeRequest() + if include_optional: + return UpdateActionTypeRequest( + service = None, + title = '', + subtitle = '', + description = '', + id = 56 + ) + else: + return UpdateActionTypeRequest( + service = None, + title = '', + description = '', + id = 56, + ) + """ + + def testUpdateActionTypeRequest(self): + """Test UpdateActionTypeRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_update_action_type_response.py b/test/test_update_action_type_response.py new file mode 100644 index 00000000..0f999e05 --- /dev/null +++ b/test/test_update_action_type_response.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.update_action_type_response import UpdateActionTypeResponse + +class TestUpdateActionTypeResponse(unittest.TestCase): + """UpdateActionTypeResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UpdateActionTypeResponse: + """Test UpdateActionTypeResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UpdateActionTypeResponse` + """ + model = UpdateActionTypeResponse() + if include_optional: + return UpdateActionTypeResponse( + service = None, + title = '', + subtitle = '', + description = '', + id = 56 + ) + else: + return UpdateActionTypeResponse( + service = None, + title = '', + description = '', + id = 56, + ) + """ + + def testUpdateActionTypeResponse(self): + """Test UpdateActionTypeResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_update_recommendation_unit_request.py b/test/test_update_recommendation_unit_request.py new file mode 100644 index 00000000..9e85cc33 --- /dev/null +++ b/test/test_update_recommendation_unit_request.py @@ -0,0 +1,80 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.update_recommendation_unit_request import UpdateRecommendationUnitRequest + +class TestUpdateRecommendationUnitRequest(unittest.TestCase): + """UpdateRecommendationUnitRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UpdateRecommendationUnitRequest: + """Test UpdateRecommendationUnitRequest + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UpdateRecommendationUnitRequest` + """ + model = UpdateRecommendationUnitRequest() + if include_optional: + return UpdateRecommendationUnitRequest( + id = '', + service = '', + action_type_id = 56, + priority = 56, + title = '', + subtitle = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ) + ) + else: + return UpdateRecommendationUnitRequest( + id = '', + service = '', + priority = 56, + title = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ), + ) + """ + + def testUpdateRecommendationUnitRequest(self): + """Test UpdateRecommendationUnitRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_update_recommendation_unit_response.py b/test/test_update_recommendation_unit_response.py new file mode 100644 index 00000000..0145fdc0 --- /dev/null +++ b/test/test_update_recommendation_unit_response.py @@ -0,0 +1,80 @@ +# coding: utf-8 + +""" + onelens-backend + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from onelens_backend_client.models.update_recommendation_unit_response import UpdateRecommendationUnitResponse + +class TestUpdateRecommendationUnitResponse(unittest.TestCase): + """UpdateRecommendationUnitResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UpdateRecommendationUnitResponse: + """Test UpdateRecommendationUnitResponse + include_option is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UpdateRecommendationUnitResponse` + """ + model = UpdateRecommendationUnitResponse() + if include_optional: + return UpdateRecommendationUnitResponse( + id = '', + service = '', + action_type_id = 56, + priority = 56, + title = '', + subtitle = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ) + ) + else: + return UpdateRecommendationUnitResponse( + id = '', + service = '', + priority = 56, + title = '', + description = '', + effort = 'Easy', + query_details = onelens_backend_client.models.recommendation_query_details.RecommendationQueryDetails( + derived_variables = [ + onelens_backend_client.models.query_details_derived_variables.QueryDetailsDerivedVariables( + key = '', + value_type = '', + source_key = '', ) + ], + query = '', ), + ) + """ + + def testUpdateRecommendationUnitResponse(self): + """Test UpdateRecommendationUnitResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main()