@ayasofyazilim/saas 0.0.71 → 0.0.73
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/release.yaml +120 -114
- package/.github/workflows/update.yaml +52 -47
- package/.github/workflows/update_release.yaml +34 -0
- package/AccountService/AccountServiceClient.ts +68 -68
- package/AccountService/core/ApiRequestOptions.ts +12 -12
- package/AccountService/core/BaseHttpRequest.ts +9 -9
- package/AccountService/core/FetchHttpRequest.ts +21 -21
- package/AccountService/core/OpenAPI.ts +55 -55
- package/AccountService/core/request.ts +340 -340
- package/AccountService/index.ts +8 -8
- package/AccountService/models/Volo_Abp_Account_AccountExternalProviderSettingsDto.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_AccountRecaptchaSettingsDto.ts +14 -14
- package/AccountService/models/Volo_Abp_Account_AccountSettingsDto.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_AccountTwoFactorSettingsDto.ts +11 -11
- package/AccountService/models/Volo_Abp_Account_AuthenticatorInfoDto.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_ChangePasswordInput.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_ConfirmEmailInput.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_ConfirmPhoneNumberInput.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_DelegateNewUserInput.ts +10 -10
- package/AccountService/models/Volo_Abp_Account_ExternalProviders_ExternalProviderDto.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_ExternalProviders_ExternalProviderItemDto.ts +11 -11
- package/AccountService/models/Volo_Abp_Account_ExternalProviders_ExternalProviderItemWithSecretDto.ts +13 -13
- package/AccountService/models/Volo_Abp_Account_ExternalProviders_ExternalProviderSettings.ts +12 -12
- package/AccountService/models/Volo_Abp_Account_ExternalProviders_ExternalProviderSettingsProperty.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_IdentityUserConfirmationStateDto.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_IsLinkedInput.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_LinkUserDto.ts +12 -12
- package/AccountService/models/Volo_Abp_Account_LinkUserInput.ts +10 -10
- package/AccountService/models/Volo_Abp_Account_ProfileDto.ts +20 -20
- package/AccountService/models/Volo_Abp_Account_ProfilePictureSourceDto.ts +11 -11
- package/AccountService/models/Volo_Abp_Account_ProfilePictureType.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_Public_Web_Areas_Account_Controllers_Models_AbpLoginResult.ts +10 -10
- package/AccountService/models/Volo_Abp_Account_Public_Web_Areas_Account_Controllers_Models_LinkUserLoginInfo.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_Public_Web_Areas_Account_Controllers_Models_LoginResultType.ts +12 -12
- package/AccountService/models/Volo_Abp_Account_Public_Web_Areas_Account_Controllers_Models_UserLoginInfo.ts +11 -11
- package/AccountService/models/Volo_Abp_Account_RegisterDto.ts +15 -15
- package/AccountService/models/Volo_Abp_Account_ResetPasswordDto.ts +10 -10
- package/AccountService/models/Volo_Abp_Account_SendEmailConfirmationTokenDto.ts +11 -11
- package/AccountService/models/Volo_Abp_Account_SendPasswordResetCodeDto.ts +11 -11
- package/AccountService/models/Volo_Abp_Account_SendPhoneNumberConfirmationTokenDto.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_SendTwoFactorCodeInput.ts +10 -10
- package/AccountService/models/Volo_Abp_Account_UnLinkUserInput.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_UpdateExternalProviderDto.ts +12 -12
- package/AccountService/models/Volo_Abp_Account_UpdateProfileDto.ts +15 -15
- package/AccountService/models/Volo_Abp_Account_UserDelegationDto.ts +11 -11
- package/AccountService/models/Volo_Abp_Account_UserLookupDto.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_VerifyAuthenticatorCodeDto.ts +8 -8
- package/AccountService/models/Volo_Abp_Account_VerifyAuthenticatorCodeInput.ts +8 -8
- package/AccountService/models/Volo_Abp_Account_VerifyEmailConfirmationTokenInput.ts +9 -9
- package/AccountService/models/Volo_Abp_Account_VerifyLinkLoginTokenInput.ts +10 -10
- package/AccountService/models/Volo_Abp_Account_VerifyLinkTokenInput.ts +10 -10
- package/AccountService/models/Volo_Abp_Account_VerifyPasswordResetTokenInput.ts +9 -9
- package/AccountService/models/Volo_Abp_Application_Dtos_ListResultDto_1.ts +9 -9
- package/AccountService/models/Volo_Abp_Application_Dtos_PagedResultDto_1.ts +10 -10
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationAuthConfigurationDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationConfigurationDto.ts +30 -30
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationFeatureConfigurationDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationGlobalFeatureConfigurationDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationConfigurationDto.ts +18 -18
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationDto.ts +9 -9
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationResourceDto.ts +9 -9
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationSettingConfigurationDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ClockDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_CurrentCultureDto.ts +17 -17
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_CurrentUserDto.ts +22 -22
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_DateTimeFormatDto.ts +14 -14
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_IanaTimeZone.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_EntityExtensionDto.ts +10 -10
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionEnumDto.ts +10 -10
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionEnumFieldDto.ts +9 -9
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiCreateDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiDto.ts +13 -13
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiGetDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiUpdateDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyAttributeDto.ts +9 -9
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyDto.ts +19 -19
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiDto.ts +14 -14
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiFormDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiLookupDto.ts +12 -12
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiTableDto.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_LocalizableStringDto.ts +9 -9
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ModuleExtensionDto.ts +10 -10
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ObjectExtensionsDto.ts +11 -11
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_TimeZone.ts +11 -11
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_TimingDto.ts +9 -9
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_WindowsTimeZone.ts +8 -8
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_MultiTenancy_CurrentTenantDto.ts +10 -10
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_MultiTenancy_FindTenantResultDto.ts +11 -11
- package/AccountService/models/Volo_Abp_AspNetCore_Mvc_MultiTenancy_MultiTenancyInfoDto.ts +8 -8
- package/AccountService/models/Volo_Abp_Http_Modeling_ActionApiDescriptionModel.ts +20 -20
- package/AccountService/models/Volo_Abp_Http_Modeling_ApplicationApiDescriptionModel.ts +11 -11
- package/AccountService/models/Volo_Abp_Http_Modeling_ControllerApiDescriptionModel.ts +17 -17
- package/AccountService/models/Volo_Abp_Http_Modeling_ControllerInterfaceApiDescriptionModel.ts +11 -11
- package/AccountService/models/Volo_Abp_Http_Modeling_InterfaceMethodApiDescriptionModel.ts +12 -12
- package/AccountService/models/Volo_Abp_Http_Modeling_MethodParameterApiDescriptionModel.ts +13 -13
- package/AccountService/models/Volo_Abp_Http_Modeling_ModuleApiDescriptionModel.ts +11 -11
- package/AccountService/models/Volo_Abp_Http_Modeling_ParameterApiDescriptionModel.ts +17 -17
- package/AccountService/models/Volo_Abp_Http_Modeling_PropertyApiDescriptionModel.ts +17 -17
- package/AccountService/models/Volo_Abp_Http_Modeling_ReturnValueApiDescriptionModel.ts +9 -9
- package/AccountService/models/Volo_Abp_Http_Modeling_TypeApiDescriptionModel.ts +14 -14
- package/AccountService/models/Volo_Abp_Http_RemoteServiceErrorInfo.ts +13 -13
- package/AccountService/models/Volo_Abp_Http_RemoteServiceErrorResponse.ts +9 -9
- package/AccountService/models/Volo_Abp_Http_RemoteServiceValidationErrorInfo.ts +9 -9
- package/AccountService/models/Volo_Abp_Identity_Features_IdentityProTwoFactorBehaviour.ts +9 -9
- package/AccountService/models/Volo_Abp_Identity_IdentitySecurityLogDto.ts +21 -21
- package/AccountService/models/Volo_Abp_Identity_IdentityUserDto.ts +35 -35
- package/AccountService/models/Volo_Abp_Localization_LanguageInfo.ts +12 -12
- package/AccountService/models/Volo_Abp_NameValue.ts +9 -9
- package/AccountService/schemas.gen.ts +5333 -5333
- package/AccountService/services/AbpApiDefinitionService.ts +34 -34
- package/AccountService/services/AbpApplicationConfigurationService.ts +34 -34
- package/AccountService/services/AbpApplicationLocalizationService.ts +37 -37
- package/AccountService/services/AbpTenantService.ts +58 -58
- package/AccountService/services/AccountExternalProviderService.ts +56 -56
- package/AccountService/services/AccountService.ts +545 -545
- package/AccountService/services/AccountSettingsService.ts +178 -178
- package/AccountService/services/DynamicClaimsService.ts +27 -27
- package/AccountService/services/LoginService.ts +99 -99
- package/AccountService/services/ProfileService.ts +155 -155
- package/AccountService/services/UserService.ts +313 -313
- package/AccountService/services.gen.ts +1539 -1539
- package/AccountService/types.gen.ts +3328 -3328
- package/AdministrationService/AdministrationServiceClient.ts +80 -77
- package/AdministrationService/core/ApiRequestOptions.ts +12 -12
- package/AdministrationService/core/BaseHttpRequest.ts +9 -9
- package/AdministrationService/core/FetchHttpRequest.ts +21 -21
- package/AdministrationService/core/OpenAPI.ts +55 -55
- package/AdministrationService/core/request.ts +340 -340
- package/AdministrationService/index.ts +8 -8
- package/AdministrationService/models/System_Net_HttpStatusCode.ts +67 -67
- package/AdministrationService/models/Volo_Abp_Application_Dtos_ListResultDto_1.ts +9 -9
- package/AdministrationService/models/Volo_Abp_Application_Dtos_PagedResultDto_1.ts +10 -10
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationAuthConfigurationDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationConfigurationDto.ts +30 -30
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationFeatureConfigurationDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationGlobalFeatureConfigurationDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationConfigurationDto.ts +18 -18
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationResourceDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationSettingConfigurationDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ClockDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_CurrentCultureDto.ts +17 -17
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_CurrentUserDto.ts +22 -22
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_DateTimeFormatDto.ts +14 -14
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_IanaTimeZone.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_EntityExtensionDto.ts +10 -10
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionEnumDto.ts +10 -10
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionEnumFieldDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiCreateDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiDto.ts +13 -13
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiGetDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiUpdateDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyAttributeDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyDto.ts +19 -19
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiDto.ts +14 -14
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiFormDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiLookupDto.ts +12 -12
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiTableDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_LocalizableStringDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ModuleExtensionDto.ts +10 -10
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ObjectExtensionsDto.ts +11 -11
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_TimeZone.ts +11 -11
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_TimingDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_WindowsTimeZone.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_MultiTenancy_CurrentTenantDto.ts +10 -10
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_MultiTenancy_FindTenantResultDto.ts +11 -11
- package/AdministrationService/models/Volo_Abp_AspNetCore_Mvc_MultiTenancy_MultiTenancyInfoDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AuditLogging_AuditLogActionDto.ts +16 -16
- package/AdministrationService/models/Volo_Abp_AuditLogging_AuditLogDto.ts +33 -33
- package/AdministrationService/models/Volo_Abp_AuditLogging_EntityChangeDto.ts +18 -18
- package/AdministrationService/models/Volo_Abp_AuditLogging_EntityChangeWithUsernameDto.ts +10 -10
- package/AdministrationService/models/Volo_Abp_AuditLogging_EntityPropertyChangeDto.ts +14 -14
- package/AdministrationService/models/Volo_Abp_AuditLogging_GetAverageExecutionDurationPerDayOutput.ts +8 -8
- package/AdministrationService/models/Volo_Abp_AuditLogging_GetErrorRateOutput.ts +8 -8
- package/AdministrationService/models/Volo_Abp_Auditing_EntityChangeType.ts +9 -9
- package/AdministrationService/models/Volo_Abp_FeatureManagement_FeatureDto.ts +17 -17
- package/AdministrationService/models/Volo_Abp_FeatureManagement_FeatureGroupDto.ts +11 -11
- package/AdministrationService/models/Volo_Abp_FeatureManagement_FeatureProviderDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_FeatureManagement_GetFeatureListResultDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_FeatureManagement_UpdateFeatureDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_FeatureManagement_UpdateFeaturesDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_Gdpr_DownloadTokenResultDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_Gdpr_GdprRequestDto.ts +10 -10
- package/AdministrationService/models/Volo_Abp_Http_Modeling_ActionApiDescriptionModel.ts +20 -20
- package/AdministrationService/models/Volo_Abp_Http_Modeling_ApplicationApiDescriptionModel.ts +11 -11
- package/AdministrationService/models/Volo_Abp_Http_Modeling_ControllerApiDescriptionModel.ts +17 -17
- package/AdministrationService/models/Volo_Abp_Http_Modeling_ControllerInterfaceApiDescriptionModel.ts +11 -11
- package/AdministrationService/models/Volo_Abp_Http_Modeling_InterfaceMethodApiDescriptionModel.ts +12 -12
- package/AdministrationService/models/Volo_Abp_Http_Modeling_MethodParameterApiDescriptionModel.ts +13 -13
- package/AdministrationService/models/Volo_Abp_Http_Modeling_ModuleApiDescriptionModel.ts +11 -11
- package/AdministrationService/models/Volo_Abp_Http_Modeling_ParameterApiDescriptionModel.ts +17 -17
- package/AdministrationService/models/Volo_Abp_Http_Modeling_PropertyApiDescriptionModel.ts +17 -17
- package/AdministrationService/models/Volo_Abp_Http_Modeling_ReturnValueApiDescriptionModel.ts +9 -9
- package/AdministrationService/models/Volo_Abp_Http_Modeling_TypeApiDescriptionModel.ts +14 -14
- package/AdministrationService/models/Volo_Abp_Http_RemoteServiceErrorInfo.ts +13 -13
- package/AdministrationService/models/Volo_Abp_Http_RemoteServiceErrorResponse.ts +9 -9
- package/AdministrationService/models/Volo_Abp_Http_RemoteServiceValidationErrorInfo.ts +9 -9
- package/AdministrationService/models/Volo_Abp_LanguageManagement_Dto_CreateLanguageDto.ts +13 -13
- package/AdministrationService/models/Volo_Abp_LanguageManagement_Dto_CultureInfoDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_LanguageManagement_Dto_LanguageDto.ts +18 -18
- package/AdministrationService/models/Volo_Abp_LanguageManagement_Dto_LanguageResourceDto.ts +8 -8
- package/AdministrationService/models/Volo_Abp_LanguageManagement_Dto_LanguageTextDto.ts +13 -13
- package/AdministrationService/models/Volo_Abp_LanguageManagement_Dto_UpdateLanguageDto.ts +12 -12
- package/AdministrationService/models/Volo_Abp_Localization_LanguageInfo.ts +12 -12
- package/AdministrationService/models/Volo_Abp_NameValue.ts +9 -9
- package/AdministrationService/models/Volo_Abp_PermissionManagement_GetPermissionListResultDto.ts +10 -10
- package/AdministrationService/models/Volo_Abp_PermissionManagement_PermissionGrantInfoDto.ts +14 -14
- package/AdministrationService/models/Volo_Abp_PermissionManagement_PermissionGroupDto.ts +13 -13
- package/AdministrationService/models/Volo_Abp_PermissionManagement_ProviderInfoDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_PermissionManagement_UpdatePermissionDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_PermissionManagement_UpdatePermissionsDto.ts +9 -9
- package/AdministrationService/models/Volo_Abp_SettingManagement_EmailSettingsDto.ts +16 -16
- package/AdministrationService/models/Volo_Abp_SettingManagement_SendTestEmailInput.ts +11 -11
- package/AdministrationService/models/Volo_Abp_SettingManagement_UpdateEmailSettingsDto.ts +16 -16
- package/AdministrationService/models/Volo_Abp_TextTemplateManagement_TextTemplates_RestoreTemplateContentInput.ts +9 -9
- package/AdministrationService/models/Volo_Abp_TextTemplateManagement_TextTemplates_TemplateDefinitionDto.ts +13 -13
- package/AdministrationService/models/Volo_Abp_TextTemplateManagement_TextTemplates_TextTemplateContentDto.ts +10 -10
- package/AdministrationService/models/Volo_Abp_TextTemplateManagement_TextTemplates_UpdateTemplateContentInput.ts +10 -10
- package/AdministrationService/models/Volo_Abp_Validation_StringValues_IStringValueType.ts +11 -11
- package/AdministrationService/models/Volo_Abp_Validation_StringValues_IValueValidator.ts +9 -9
- package/AdministrationService/schemas.gen.ts +6721 -5987
- package/AdministrationService/services/AbpApiDefinitionService.ts +34 -34
- package/AdministrationService/services/AbpApplicationConfigurationService.ts +34 -34
- package/AdministrationService/services/AbpApplicationLocalizationService.ts +37 -37
- package/AdministrationService/services/AbpTenantService.ts +58 -58
- package/AdministrationService/services/AuditLogsService.ts +286 -286
- package/AdministrationService/services/EmailSettingsService.ts +76 -76
- package/AdministrationService/services/FeaturesService.ts +96 -96
- package/AdministrationService/services/GdprRequestService.ts +152 -152
- package/AdministrationService/services/LanguageTextsService.ts +157 -157
- package/AdministrationService/services/LanguagesService.ts +257 -257
- package/AdministrationService/services/PermissionsService.ts +69 -69
- package/AdministrationService/services/TextTemplateContentsService.ts +85 -85
- package/AdministrationService/services/TextTemplateDefinitionsService.ts +69 -69
- package/AdministrationService/services/TimeZoneSettingsService.ts +70 -70
- package/AdministrationService/services.gen.ts +1470 -1404
- package/AdministrationService/types.gen.ts +3034 -2851
- package/BackerService/core/ApiRequestOptions.ts +12 -12
- package/BackerService/core/BaseHttpRequest.ts +9 -9
- package/BackerService/core/FetchHttpRequest.ts +21 -21
- package/BackerService/core/OpenAPI.ts +55 -55
- package/BackerService/core/request.ts +340 -340
- package/BackerService/index.ts +8 -8
- package/BackerService/services.gen.ts +866 -866
- package/BackerService/types.gen.ts +2170 -2170
- package/CRMService/CRMServiceClient.ts +65 -65
- package/CRMService/schemas.gen.ts +18542 -18542
- package/CRMService/services.gen.ts +2636 -2636
- package/CRMService/types.gen.ts +5238 -5238
- package/ContractService/schemas.gen.ts +11791 -11791
- package/ContractService/services.gen.ts +1962 -1962
- package/ContractService/types.gen.ts +4257 -4257
- package/ExportValidationService/ExportValidationServiceClient.ts +44 -44
- package/ExportValidationService/core/ApiError.ts +20 -20
- package/ExportValidationService/core/ApiRequestOptions.ts +12 -12
- package/ExportValidationService/core/ApiResult.ts +6 -6
- package/ExportValidationService/core/BaseHttpRequest.ts +9 -9
- package/ExportValidationService/core/CancelablePromise.ts +125 -125
- package/ExportValidationService/core/FetchHttpRequest.ts +21 -21
- package/ExportValidationService/core/OpenAPI.ts +55 -55
- package/ExportValidationService/core/request.ts +340 -340
- package/ExportValidationService/index.ts +8 -8
- package/ExportValidationService/schemas.gen.ts +3998 -3998
- package/ExportValidationService/services.gen.ts +260 -260
- package/ExportValidationService/types.gen.ts +818 -818
- package/FinanceService/FinanceServiceClient.ts +44 -44
- package/FinanceService/core/ApiError.ts +20 -20
- package/FinanceService/core/ApiRequestOptions.ts +12 -12
- package/FinanceService/core/ApiResult.ts +6 -6
- package/FinanceService/core/BaseHttpRequest.ts +9 -9
- package/FinanceService/core/CancelablePromise.ts +125 -125
- package/FinanceService/core/FetchHttpRequest.ts +21 -21
- package/FinanceService/core/OpenAPI.ts +55 -55
- package/FinanceService/core/request.ts +340 -340
- package/FinanceService/index.ts +8 -8
- package/FinanceService/schemas.gen.ts +4137 -3969
- package/FinanceService/services.gen.ts +224 -224
- package/FinanceService/types.gen.ts +778 -759
- package/FundraiserService/core/ApiRequestOptions.ts +12 -12
- package/FundraiserService/core/BaseHttpRequest.ts +9 -9
- package/FundraiserService/core/FetchHttpRequest.ts +21 -21
- package/FundraiserService/core/OpenAPI.ts +55 -55
- package/FundraiserService/core/request.ts +340 -340
- package/FundraiserService/index.ts +8 -8
- package/FundraiserService/services.gen.ts +627 -627
- package/FundraiserService/types.gen.ts +1793 -1793
- package/IdentityService/IdentityServiceClient.ts +80 -80
- package/IdentityService/core/ApiRequestOptions.ts +12 -12
- package/IdentityService/core/BaseHttpRequest.ts +9 -9
- package/IdentityService/core/FetchHttpRequest.ts +21 -21
- package/IdentityService/core/OpenAPI.ts +55 -55
- package/IdentityService/core/request.ts +340 -340
- package/IdentityService/index.ts +8 -8
- package/IdentityService/models/Volo_Abp_Account_AccountExternalProviderSettingsDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_Account_AccountRecaptchaSettingsDto.ts +14 -14
- package/IdentityService/models/Volo_Abp_Account_AccountSettingsDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_Account_AccountTwoFactorSettingsDto.ts +11 -11
- package/IdentityService/models/Volo_Abp_Account_ExternalProviders_ExternalProviderSettings.ts +12 -12
- package/IdentityService/models/Volo_Abp_Account_ExternalProviders_ExternalProviderSettingsProperty.ts +9 -9
- package/IdentityService/models/Volo_Abp_Account_UpdateExternalProviderDto.ts +12 -12
- package/IdentityService/models/Volo_Abp_Application_Dtos_ListResultDto_1.ts +9 -9
- package/IdentityService/models/Volo_Abp_Application_Dtos_PagedResultDto_1.ts +10 -10
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationAuthConfigurationDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationConfigurationDto.ts +30 -30
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationFeatureConfigurationDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationGlobalFeatureConfigurationDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationConfigurationDto.ts +18 -18
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationLocalizationResourceDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ApplicationSettingConfigurationDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ClockDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_CurrentCultureDto.ts +17 -17
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_CurrentUserDto.ts +22 -22
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_DateTimeFormatDto.ts +14 -14
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_IanaTimeZone.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_EntityExtensionDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionEnumDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionEnumFieldDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiCreateDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiDto.ts +13 -13
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiGetDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyApiUpdateDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyAttributeDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyDto.ts +19 -19
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiDto.ts +14 -14
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiFormDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiLookupDto.ts +12 -12
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ExtensionPropertyUiTableDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_LocalizableStringDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ModuleExtensionDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_ObjectExtending_ObjectExtensionsDto.ts +11 -11
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_TimeZone.ts +11 -11
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_TimingDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_ApplicationConfigurations_WindowsTimeZone.ts +8 -8
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_MultiTenancy_CurrentTenantDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_AspNetCore_Mvc_MultiTenancy_MultiTenancyInfoDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_Http_Modeling_ActionApiDescriptionModel.ts +20 -20
- package/IdentityService/models/Volo_Abp_Http_Modeling_ApplicationApiDescriptionModel.ts +11 -11
- package/IdentityService/models/Volo_Abp_Http_Modeling_ControllerApiDescriptionModel.ts +17 -17
- package/IdentityService/models/Volo_Abp_Http_Modeling_ControllerInterfaceApiDescriptionModel.ts +11 -11
- package/IdentityService/models/Volo_Abp_Http_Modeling_InterfaceMethodApiDescriptionModel.ts +12 -12
- package/IdentityService/models/Volo_Abp_Http_Modeling_MethodParameterApiDescriptionModel.ts +13 -13
- package/IdentityService/models/Volo_Abp_Http_Modeling_ModuleApiDescriptionModel.ts +11 -11
- package/IdentityService/models/Volo_Abp_Http_Modeling_ParameterApiDescriptionModel.ts +17 -17
- package/IdentityService/models/Volo_Abp_Http_Modeling_PropertyApiDescriptionModel.ts +17 -17
- package/IdentityService/models/Volo_Abp_Http_Modeling_ReturnValueApiDescriptionModel.ts +9 -9
- package/IdentityService/models/Volo_Abp_Http_Modeling_TypeApiDescriptionModel.ts +14 -14
- package/IdentityService/models/Volo_Abp_Http_RemoteServiceErrorInfo.ts +13 -13
- package/IdentityService/models/Volo_Abp_Http_RemoteServiceErrorResponse.ts +9 -9
- package/IdentityService/models/Volo_Abp_Http_RemoteServiceValidationErrorInfo.ts +9 -9
- package/IdentityService/models/Volo_Abp_Identity_ClaimTypeDto.ts +19 -19
- package/IdentityService/models/Volo_Abp_Identity_CreateClaimTypeDto.ts +15 -15
- package/IdentityService/models/Volo_Abp_Identity_DownloadTokenResultDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_Identity_ExternalLoginProviderDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_Identity_Features_IdentityProTwoFactorBehaviour.ts +9 -9
- package/IdentityService/models/Volo_Abp_Identity_IdentityClaimValueType.ts +10 -10
- package/IdentityService/models/Volo_Abp_Identity_IdentityLdapSettingsDto.ts +15 -15
- package/IdentityService/models/Volo_Abp_Identity_IdentityLockoutSettingsDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_Identity_IdentityOAuthSettingsDto.ts +15 -15
- package/IdentityService/models/Volo_Abp_Identity_IdentityPasswordSettingsDto.ts +15 -15
- package/IdentityService/models/Volo_Abp_Identity_IdentityRoleClaimDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_Identity_IdentityRoleCreateDto.ts +11 -11
- package/IdentityService/models/Volo_Abp_Identity_IdentityRoleDto.ts +15 -15
- package/IdentityService/models/Volo_Abp_Identity_IdentityRoleLookupDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_Identity_IdentityRoleUpdateDto.ts +12 -12
- package/IdentityService/models/Volo_Abp_Identity_IdentitySecurityLogDto.ts +21 -21
- package/IdentityService/models/Volo_Abp_Identity_IdentitySettingsDto.ts +15 -15
- package/IdentityService/models/Volo_Abp_Identity_IdentitySignInSettingsDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_Identity_IdentityUserClaimDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_Identity_IdentityUserCreateDto.ts +20 -20
- package/IdentityService/models/Volo_Abp_Identity_IdentityUserDto.ts +35 -35
- package/IdentityService/models/Volo_Abp_Identity_IdentityUserSettingsDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_Identity_IdentityUserUpdateDto.ts +19 -19
- package/IdentityService/models/Volo_Abp_Identity_IdentityUserUpdatePasswordInput.ts +8 -8
- package/IdentityService/models/Volo_Abp_Identity_IdentityUserUpdateRolesDto.ts +8 -8
- package/IdentityService/models/Volo_Abp_Identity_ImportExternalUserInput.ts +10 -10
- package/IdentityService/models/Volo_Abp_Identity_ImportUsersFromFileOutput.ts +12 -12
- package/IdentityService/models/Volo_Abp_Identity_ImportUsersFromFileType.ts +8 -8
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitCreateDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitDto.ts +21 -21
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitLookupDto.ts +9 -9
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitMoveInput.ts +8 -8
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitRoleDto.ts +11 -11
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitRoleInput.ts +8 -8
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitUpdateDto.ts +10 -10
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitUserInput.ts +8 -8
- package/IdentityService/models/Volo_Abp_Identity_OrganizationUnitWithDetailsDto.ts +23 -23
- package/IdentityService/models/Volo_Abp_Identity_UpdateClaimTypeDto.ts +16 -16
- package/IdentityService/models/Volo_Abp_Localization_LanguageInfo.ts +12 -12
- package/IdentityService/models/Volo_Abp_NameValue.ts +9 -9
- package/IdentityService/models/Volo_Abp_OpenIddict_Applications_Dtos_ApplicationDto.ts +29 -29
- package/IdentityService/models/Volo_Abp_OpenIddict_Applications_Dtos_ApplicationTokenLifetimeDto.ts +13 -13
- package/IdentityService/models/Volo_Abp_OpenIddict_Applications_Dtos_CreateApplicationInput.ts +28 -28
- package/IdentityService/models/Volo_Abp_OpenIddict_Applications_Dtos_UpdateApplicationInput.ts +28 -28
- package/IdentityService/models/Volo_Abp_OpenIddict_Scopes_Dtos_CreateScopeInput.ts +12 -12
- package/IdentityService/models/Volo_Abp_OpenIddict_Scopes_Dtos_ScopeDto.ts +14 -14
- package/IdentityService/models/Volo_Abp_OpenIddict_Scopes_Dtos_UpdateScopeInput.ts +12 -12
- package/IdentityService/models/Volo_Abp_Users_UserData.ts +18 -18
- package/IdentityService/schemas.gen.ts +6845 -6845
- package/IdentityService/services/AbpApiDefinitionService.ts +34 -34
- package/IdentityService/services/AbpApplicationConfigurationService.ts +34 -34
- package/IdentityService/services/AbpApplicationLocalizationService.ts +37 -37
- package/IdentityService/services/AccountSettingsService.ts +178 -178
- package/IdentityService/services/ApplicationsService.ts +199 -199
- package/IdentityService/services/ClaimTypeService.ts +149 -149
- package/IdentityService/services/ExternalLoginService.ts +27 -27
- package/IdentityService/services/OrganizationUnitService.ts +539 -539
- package/IdentityService/services/RoleService.ts +269 -269
- package/IdentityService/services/ScopesService.ts +164 -164
- package/IdentityService/services/SecurityLogService.ts +174 -174
- package/IdentityService/services/SettingsService.ts +135 -135
- package/IdentityService/services/UserIntegrationService.ts +144 -144
- package/IdentityService/services/UserLookupService.ts +120 -120
- package/IdentityService/services/UserService.ts +937 -937
- package/IdentityService/services.gen.ts +2924 -2924
- package/IdentityService/types.gen.ts +5484 -5484
- package/LocationService/LocationServiceClient.ts +74 -74
- package/LocationService/core/ApiError.ts +20 -20
- package/LocationService/core/ApiRequestOptions.ts +12 -12
- package/LocationService/core/ApiResult.ts +6 -6
- package/LocationService/core/BaseHttpRequest.ts +9 -9
- package/LocationService/core/CancelablePromise.ts +125 -125
- package/LocationService/core/FetchHttpRequest.ts +21 -21
- package/LocationService/core/OpenAPI.ts +55 -55
- package/LocationService/core/request.ts +340 -340
- package/LocationService/index.ts +8 -8
- package/LocationService/schemas.gen.ts +6635 -6635
- package/LocationService/services.gen.ts +1797 -1797
- package/LocationService/types.gen.ts +3738 -3738
- package/MerchantService/core/ApiRequestOptions.ts +12 -12
- package/MerchantService/core/BaseHttpRequest.ts +9 -9
- package/MerchantService/core/FetchHttpRequest.ts +21 -21
- package/MerchantService/core/OpenAPI.ts +55 -55
- package/MerchantService/core/request.ts +340 -340
- package/MerchantService/types.gen.ts +18875 -18875
- package/ProjectService/core/ApiRequestOptions.ts +12 -12
- package/ProjectService/core/BaseHttpRequest.ts +9 -9
- package/ProjectService/core/FetchHttpRequest.ts +21 -21
- package/ProjectService/core/OpenAPI.ts +55 -55
- package/ProjectService/core/request.ts +340 -340
- package/ProjectService/index.ts +8 -8
- package/ProjectService/services.gen.ts +492 -492
- package/ProjectService/types.gen.ts +1303 -1303
- package/README.md +38 -38
- package/SaasService/core/ApiRequestOptions.ts +12 -12
- package/SaasService/core/BaseHttpRequest.ts +9 -9
- package/SaasService/core/FetchHttpRequest.ts +21 -21
- package/SaasService/core/OpenAPI.ts +55 -55
- package/SaasService/core/request.ts +340 -340
- package/SaasService/index.ts +8 -8
- package/SaasService/schemas.gen.ts +5345 -5345
- package/SaasService/services.gen.ts +1329 -1329
- package/SaasService/types.gen.ts +2737 -2737
- package/SettingService/SettingServiceClient.ts +59 -59
- package/SettingService/schemas.gen.ts +5223 -5223
- package/SettingService/services.gen.ts +758 -758
- package/SettingService/types.gen.ts +1800 -1800
- package/TagService/TagServiceClient.ts +44 -44
- package/TagService/core/ApiError.ts +20 -20
- package/TagService/core/ApiRequestOptions.ts +12 -12
- package/TagService/core/ApiResult.ts +6 -6
- package/TagService/core/BaseHttpRequest.ts +9 -9
- package/TagService/core/CancelablePromise.ts +125 -125
- package/TagService/core/FetchHttpRequest.ts +21 -21
- package/TagService/core/OpenAPI.ts +55 -55
- package/TagService/core/request.ts +340 -340
- package/TagService/index.ts +8 -8
- package/TagService/schemas.gen.ts +5109 -5109
- package/TagService/services.gen.ts +361 -361
- package/TagService/types.gen.ts +1088 -1088
- package/TravellerService/TravellerServiceClient.ts +56 -56
- package/TravellerService/core/ApiError.ts +20 -20
- package/TravellerService/core/ApiRequestOptions.ts +12 -12
- package/TravellerService/core/ApiResult.ts +6 -6
- package/TravellerService/core/BaseHttpRequest.ts +9 -9
- package/TravellerService/core/CancelablePromise.ts +125 -125
- package/TravellerService/core/FetchHttpRequest.ts +21 -21
- package/TravellerService/core/OpenAPI.ts +55 -55
- package/TravellerService/core/request.ts +340 -340
- package/TravellerService/index.ts +8 -8
- package/TravellerService/schemas.gen.ts +6347 -6347
- package/TravellerService/services.gen.ts +845 -845
- package/TravellerService/types.gen.ts +2072 -2072
- package/generator.mjs +204 -204
- package/index.ts +2 -2
- package/package.json +28 -28
|
@@ -1,341 +1,341 @@
|
|
|
1
|
-
import { ApiError } from './ApiError';
|
|
2
|
-
import type { ApiRequestOptions } from './ApiRequestOptions';
|
|
3
|
-
import type { ApiResult } from './ApiResult';
|
|
4
|
-
import { CancelablePromise } from './CancelablePromise';
|
|
5
|
-
import type { OnCancel } from './CancelablePromise';
|
|
6
|
-
import type { OpenAPIConfig } from './OpenAPI';
|
|
7
|
-
|
|
8
|
-
export const isString = (value: unknown): value is string => {
|
|
9
|
-
return typeof value === 'string';
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
export const isStringWithValue = (value: unknown): value is string => {
|
|
13
|
-
return isString(value) && value !== '';
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
export const isBlob = (value: any): value is Blob => {
|
|
17
|
-
return value instanceof Blob;
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
export const isFormData = (value: unknown): value is FormData => {
|
|
21
|
-
return value instanceof FormData;
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
export const base64 = (str: string): string => {
|
|
25
|
-
try {
|
|
26
|
-
return btoa(str);
|
|
27
|
-
} catch (err) {
|
|
28
|
-
// @ts-ignore
|
|
29
|
-
return Buffer.from(str).toString('base64');
|
|
30
|
-
}
|
|
31
|
-
};
|
|
32
|
-
|
|
33
|
-
export const getQueryString = (params: Record<string, unknown>): string => {
|
|
34
|
-
const qs: string[] = [];
|
|
35
|
-
|
|
36
|
-
const append = (key: string, value: unknown) => {
|
|
37
|
-
qs.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`);
|
|
38
|
-
};
|
|
39
|
-
|
|
40
|
-
const encodePair = (key: string, value: unknown) => {
|
|
41
|
-
if (value === undefined || value === null) {
|
|
42
|
-
return;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
if (value instanceof Date) {
|
|
46
|
-
append(key, value.toISOString());
|
|
47
|
-
} else if (Array.isArray(value)) {
|
|
48
|
-
value.forEach(v => encodePair(key, v));
|
|
49
|
-
} else if (typeof value === 'object') {
|
|
50
|
-
Object.entries(value).forEach(([k, v]) => encodePair(`${key}[${k}]`, v));
|
|
51
|
-
} else {
|
|
52
|
-
append(key, value);
|
|
53
|
-
}
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
Object.entries(params).forEach(([key, value]) => encodePair(key, value));
|
|
57
|
-
|
|
58
|
-
return qs.length ? `?${qs.join('&')}` : '';
|
|
59
|
-
};
|
|
60
|
-
|
|
61
|
-
const getUrl = (config: OpenAPIConfig, options: ApiRequestOptions): string => {
|
|
62
|
-
const encoder = config.ENCODE_PATH || encodeURI;
|
|
63
|
-
|
|
64
|
-
const path = options.url
|
|
65
|
-
.replace('{api-version}', config.VERSION)
|
|
66
|
-
.replace(/{(.*?)}/g, (substring: string, group: string) => {
|
|
67
|
-
if (options.path?.hasOwnProperty(group)) {
|
|
68
|
-
return encoder(String(options.path[group]));
|
|
69
|
-
}
|
|
70
|
-
return substring;
|
|
71
|
-
});
|
|
72
|
-
|
|
73
|
-
const url = config.BASE + path;
|
|
74
|
-
return options.query ? url + getQueryString(options.query) : url;
|
|
75
|
-
};
|
|
76
|
-
|
|
77
|
-
export const getFormData = (options: ApiRequestOptions): FormData | undefined => {
|
|
78
|
-
if (options.formData) {
|
|
79
|
-
const formData = new FormData();
|
|
80
|
-
|
|
81
|
-
const process = (key: string, value: unknown) => {
|
|
82
|
-
if (isString(value) || isBlob(value)) {
|
|
83
|
-
formData.append(key, value);
|
|
84
|
-
} else {
|
|
85
|
-
formData.append(key, JSON.stringify(value));
|
|
86
|
-
}
|
|
87
|
-
};
|
|
88
|
-
|
|
89
|
-
Object.entries(options.formData)
|
|
90
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
91
|
-
.forEach(([key, value]) => {
|
|
92
|
-
if (Array.isArray(value)) {
|
|
93
|
-
value.forEach(v => process(key, v));
|
|
94
|
-
} else {
|
|
95
|
-
process(key, value);
|
|
96
|
-
}
|
|
97
|
-
});
|
|
98
|
-
|
|
99
|
-
return formData;
|
|
100
|
-
}
|
|
101
|
-
return undefined;
|
|
102
|
-
};
|
|
103
|
-
|
|
104
|
-
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>;
|
|
105
|
-
|
|
106
|
-
export const resolve = async <T>(options: ApiRequestOptions, resolver?: T | Resolver<T>): Promise<T | undefined> => {
|
|
107
|
-
if (typeof resolver === 'function') {
|
|
108
|
-
return (resolver as Resolver<T>)(options);
|
|
109
|
-
}
|
|
110
|
-
return resolver;
|
|
111
|
-
};
|
|
112
|
-
|
|
113
|
-
export const getHeaders = async (config: OpenAPIConfig, options: ApiRequestOptions): Promise<Headers> => {
|
|
114
|
-
const [token, username, password, additionalHeaders] = await Promise.all([
|
|
115
|
-
resolve(options, config.TOKEN),
|
|
116
|
-
resolve(options, config.USERNAME),
|
|
117
|
-
resolve(options, config.PASSWORD),
|
|
118
|
-
resolve(options, config.HEADERS),
|
|
119
|
-
]);
|
|
120
|
-
|
|
121
|
-
const headers = Object.entries({
|
|
122
|
-
Accept: 'application/json',
|
|
123
|
-
...additionalHeaders,
|
|
124
|
-
...options.headers,
|
|
125
|
-
})
|
|
126
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
127
|
-
.reduce((headers, [key, value]) => ({
|
|
128
|
-
...headers,
|
|
129
|
-
[key]: String(value),
|
|
130
|
-
}), {} as Record<string, string>);
|
|
131
|
-
|
|
132
|
-
if (isStringWithValue(token)) {
|
|
133
|
-
headers['Authorization'] = `Bearer ${token}`;
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
if (isStringWithValue(username) && isStringWithValue(password)) {
|
|
137
|
-
const credentials = base64(`${username}:${password}`);
|
|
138
|
-
headers['Authorization'] = `Basic ${credentials}`;
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
if (options.body !== undefined) {
|
|
142
|
-
if (options.mediaType) {
|
|
143
|
-
headers['Content-Type'] = options.mediaType;
|
|
144
|
-
} else if (isBlob(options.body)) {
|
|
145
|
-
headers['Content-Type'] = options.body.type || 'application/octet-stream';
|
|
146
|
-
} else if (isString(options.body)) {
|
|
147
|
-
headers['Content-Type'] = 'text/plain';
|
|
148
|
-
} else if (!isFormData(options.body)) {
|
|
149
|
-
headers['Content-Type'] = 'application/json';
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
return new Headers(headers);
|
|
154
|
-
};
|
|
155
|
-
|
|
156
|
-
export const getRequestBody = (options: ApiRequestOptions): unknown => {
|
|
157
|
-
if (options.body !== undefined) {
|
|
158
|
-
if (options.mediaType?.includes('application/json') || options.mediaType?.includes('+json')) {
|
|
159
|
-
return JSON.stringify(options.body);
|
|
160
|
-
} else if (isString(options.body) || isBlob(options.body) || isFormData(options.body)) {
|
|
161
|
-
return options.body;
|
|
162
|
-
} else {
|
|
163
|
-
return JSON.stringify(options.body);
|
|
164
|
-
}
|
|
165
|
-
}
|
|
166
|
-
return undefined;
|
|
167
|
-
};
|
|
168
|
-
|
|
169
|
-
export const sendRequest = async (
|
|
170
|
-
config: OpenAPIConfig,
|
|
171
|
-
options: ApiRequestOptions,
|
|
172
|
-
url: string,
|
|
173
|
-
body: any,
|
|
174
|
-
formData: FormData | undefined,
|
|
175
|
-
headers: Headers,
|
|
176
|
-
onCancel: OnCancel
|
|
177
|
-
): Promise<Response> => {
|
|
178
|
-
const controller = new AbortController();
|
|
179
|
-
|
|
180
|
-
let request: RequestInit = {
|
|
181
|
-
headers,
|
|
182
|
-
body: body ?? formData,
|
|
183
|
-
method: options.method,
|
|
184
|
-
signal: controller.signal,
|
|
185
|
-
};
|
|
186
|
-
|
|
187
|
-
if (config.WITH_CREDENTIALS) {
|
|
188
|
-
request.credentials = config.CREDENTIALS;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
for (const fn of config.interceptors.request._fns) {
|
|
192
|
-
request = await fn(request);
|
|
193
|
-
}
|
|
194
|
-
|
|
195
|
-
onCancel(() => controller.abort());
|
|
196
|
-
|
|
197
|
-
return await fetch(url, request);
|
|
198
|
-
};
|
|
199
|
-
|
|
200
|
-
export const getResponseHeader = (response: Response, responseHeader?: string): string | undefined => {
|
|
201
|
-
if (responseHeader) {
|
|
202
|
-
const content = response.headers.get(responseHeader);
|
|
203
|
-
if (isString(content)) {
|
|
204
|
-
return content;
|
|
205
|
-
}
|
|
206
|
-
}
|
|
207
|
-
return undefined;
|
|
208
|
-
};
|
|
209
|
-
|
|
210
|
-
export const getResponseBody = async (response: Response): Promise<unknown> => {
|
|
211
|
-
if (response.status !== 204) {
|
|
212
|
-
try {
|
|
213
|
-
const contentType = response.headers.get('Content-Type');
|
|
214
|
-
if (contentType) {
|
|
215
|
-
const binaryTypes = ['application/octet-stream', 'application/pdf', 'application/zip', 'audio/', 'image/', 'video/'];
|
|
216
|
-
if (contentType.includes('application/json') || contentType.includes('+json')) {
|
|
217
|
-
return await response.json();
|
|
218
|
-
} else if (binaryTypes.some(type => contentType.includes(type))) {
|
|
219
|
-
return await response.blob();
|
|
220
|
-
} else if (contentType.includes('multipart/form-data')) {
|
|
221
|
-
return await response.formData();
|
|
222
|
-
} else if (contentType.includes('text/')) {
|
|
223
|
-
return await response.text();
|
|
224
|
-
}
|
|
225
|
-
}
|
|
226
|
-
} catch (error) {
|
|
227
|
-
console.error(error);
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
return undefined;
|
|
231
|
-
};
|
|
232
|
-
|
|
233
|
-
export const catchErrorCodes = (options: ApiRequestOptions, result: ApiResult): void => {
|
|
234
|
-
const errors: Record<number, string> = {
|
|
235
|
-
400: 'Bad Request',
|
|
236
|
-
401: 'Unauthorized',
|
|
237
|
-
402: 'Payment Required',
|
|
238
|
-
403: 'Forbidden',
|
|
239
|
-
404: 'Not Found',
|
|
240
|
-
405: 'Method Not Allowed',
|
|
241
|
-
406: 'Not Acceptable',
|
|
242
|
-
407: 'Proxy Authentication Required',
|
|
243
|
-
408: 'Request Timeout',
|
|
244
|
-
409: 'Conflict',
|
|
245
|
-
410: 'Gone',
|
|
246
|
-
411: 'Length Required',
|
|
247
|
-
412: 'Precondition Failed',
|
|
248
|
-
413: 'Payload Too Large',
|
|
249
|
-
414: 'URI Too Long',
|
|
250
|
-
415: 'Unsupported Media Type',
|
|
251
|
-
416: 'Range Not Satisfiable',
|
|
252
|
-
417: 'Expectation Failed',
|
|
253
|
-
418: 'Im a teapot',
|
|
254
|
-
421: 'Misdirected Request',
|
|
255
|
-
422: 'Unprocessable Content',
|
|
256
|
-
423: 'Locked',
|
|
257
|
-
424: 'Failed Dependency',
|
|
258
|
-
425: 'Too Early',
|
|
259
|
-
426: 'Upgrade Required',
|
|
260
|
-
428: 'Precondition Required',
|
|
261
|
-
429: 'Too Many Requests',
|
|
262
|
-
431: 'Request Header Fields Too Large',
|
|
263
|
-
451: 'Unavailable For Legal Reasons',
|
|
264
|
-
500: 'Internal Server Error',
|
|
265
|
-
501: 'Not Implemented',
|
|
266
|
-
502: 'Bad Gateway',
|
|
267
|
-
503: 'Service Unavailable',
|
|
268
|
-
504: 'Gateway Timeout',
|
|
269
|
-
505: 'HTTP Version Not Supported',
|
|
270
|
-
506: 'Variant Also Negotiates',
|
|
271
|
-
507: 'Insufficient Storage',
|
|
272
|
-
508: 'Loop Detected',
|
|
273
|
-
510: 'Not Extended',
|
|
274
|
-
511: 'Network Authentication Required',
|
|
275
|
-
...options.errors,
|
|
276
|
-
}
|
|
277
|
-
|
|
278
|
-
const error = errors[result.status];
|
|
279
|
-
if (error) {
|
|
280
|
-
throw new ApiError(options, result, error);
|
|
281
|
-
}
|
|
282
|
-
|
|
283
|
-
if (!result.ok) {
|
|
284
|
-
const errorStatus = result.status ?? 'unknown';
|
|
285
|
-
const errorStatusText = result.statusText ?? 'unknown';
|
|
286
|
-
const errorBody = (() => {
|
|
287
|
-
try {
|
|
288
|
-
return JSON.stringify(result.body, null, 2);
|
|
289
|
-
} catch (e) {
|
|
290
|
-
return undefined;
|
|
291
|
-
}
|
|
292
|
-
})();
|
|
293
|
-
|
|
294
|
-
throw new ApiError(options, result,
|
|
295
|
-
`Generic Error: status: ${errorStatus}; status text: ${errorStatusText}; body: ${errorBody}`
|
|
296
|
-
);
|
|
297
|
-
}
|
|
298
|
-
};
|
|
299
|
-
|
|
300
|
-
/**
|
|
301
|
-
* Request method
|
|
302
|
-
* @param config The OpenAPI configuration object
|
|
303
|
-
* @param options The request options from the service
|
|
304
|
-
* @returns CancelablePromise<T>
|
|
305
|
-
* @throws ApiError
|
|
306
|
-
*/
|
|
307
|
-
export const request = <T>(config: OpenAPIConfig, options: ApiRequestOptions): CancelablePromise<T> => {
|
|
308
|
-
return new CancelablePromise(async (resolve, reject, onCancel) => {
|
|
309
|
-
try {
|
|
310
|
-
const url = getUrl(config, options);
|
|
311
|
-
const formData = getFormData(options);
|
|
312
|
-
const body = getRequestBody(options);
|
|
313
|
-
const headers = await getHeaders(config, options);
|
|
314
|
-
|
|
315
|
-
if (!onCancel.isCancelled) {
|
|
316
|
-
let response = await sendRequest(config, options, url, body, formData, headers, onCancel);
|
|
317
|
-
|
|
318
|
-
for (const fn of config.interceptors.response._fns) {
|
|
319
|
-
response = await fn(response);
|
|
320
|
-
}
|
|
321
|
-
|
|
322
|
-
const responseBody = await getResponseBody(response);
|
|
323
|
-
const responseHeader = getResponseHeader(response, options.responseHeader);
|
|
324
|
-
|
|
325
|
-
const result: ApiResult = {
|
|
326
|
-
url,
|
|
327
|
-
ok: response.ok,
|
|
328
|
-
status: response.status,
|
|
329
|
-
statusText: response.statusText,
|
|
330
|
-
body: responseHeader ?? responseBody,
|
|
331
|
-
};
|
|
332
|
-
|
|
333
|
-
catchErrorCodes(options, result);
|
|
334
|
-
|
|
335
|
-
resolve(result.body);
|
|
336
|
-
}
|
|
337
|
-
} catch (error) {
|
|
338
|
-
reject(error);
|
|
339
|
-
}
|
|
340
|
-
});
|
|
1
|
+
import { ApiError } from './ApiError';
|
|
2
|
+
import type { ApiRequestOptions } from './ApiRequestOptions';
|
|
3
|
+
import type { ApiResult } from './ApiResult';
|
|
4
|
+
import { CancelablePromise } from './CancelablePromise';
|
|
5
|
+
import type { OnCancel } from './CancelablePromise';
|
|
6
|
+
import type { OpenAPIConfig } from './OpenAPI';
|
|
7
|
+
|
|
8
|
+
export const isString = (value: unknown): value is string => {
|
|
9
|
+
return typeof value === 'string';
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export const isStringWithValue = (value: unknown): value is string => {
|
|
13
|
+
return isString(value) && value !== '';
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
export const isBlob = (value: any): value is Blob => {
|
|
17
|
+
return value instanceof Blob;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export const isFormData = (value: unknown): value is FormData => {
|
|
21
|
+
return value instanceof FormData;
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export const base64 = (str: string): string => {
|
|
25
|
+
try {
|
|
26
|
+
return btoa(str);
|
|
27
|
+
} catch (err) {
|
|
28
|
+
// @ts-ignore
|
|
29
|
+
return Buffer.from(str).toString('base64');
|
|
30
|
+
}
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
export const getQueryString = (params: Record<string, unknown>): string => {
|
|
34
|
+
const qs: string[] = [];
|
|
35
|
+
|
|
36
|
+
const append = (key: string, value: unknown) => {
|
|
37
|
+
qs.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`);
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
const encodePair = (key: string, value: unknown) => {
|
|
41
|
+
if (value === undefined || value === null) {
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
if (value instanceof Date) {
|
|
46
|
+
append(key, value.toISOString());
|
|
47
|
+
} else if (Array.isArray(value)) {
|
|
48
|
+
value.forEach(v => encodePair(key, v));
|
|
49
|
+
} else if (typeof value === 'object') {
|
|
50
|
+
Object.entries(value).forEach(([k, v]) => encodePair(`${key}[${k}]`, v));
|
|
51
|
+
} else {
|
|
52
|
+
append(key, value);
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
Object.entries(params).forEach(([key, value]) => encodePair(key, value));
|
|
57
|
+
|
|
58
|
+
return qs.length ? `?${qs.join('&')}` : '';
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
const getUrl = (config: OpenAPIConfig, options: ApiRequestOptions): string => {
|
|
62
|
+
const encoder = config.ENCODE_PATH || encodeURI;
|
|
63
|
+
|
|
64
|
+
const path = options.url
|
|
65
|
+
.replace('{api-version}', config.VERSION)
|
|
66
|
+
.replace(/{(.*?)}/g, (substring: string, group: string) => {
|
|
67
|
+
if (options.path?.hasOwnProperty(group)) {
|
|
68
|
+
return encoder(String(options.path[group]));
|
|
69
|
+
}
|
|
70
|
+
return substring;
|
|
71
|
+
});
|
|
72
|
+
|
|
73
|
+
const url = config.BASE + path;
|
|
74
|
+
return options.query ? url + getQueryString(options.query) : url;
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
export const getFormData = (options: ApiRequestOptions): FormData | undefined => {
|
|
78
|
+
if (options.formData) {
|
|
79
|
+
const formData = new FormData();
|
|
80
|
+
|
|
81
|
+
const process = (key: string, value: unknown) => {
|
|
82
|
+
if (isString(value) || isBlob(value)) {
|
|
83
|
+
formData.append(key, value);
|
|
84
|
+
} else {
|
|
85
|
+
formData.append(key, JSON.stringify(value));
|
|
86
|
+
}
|
|
87
|
+
};
|
|
88
|
+
|
|
89
|
+
Object.entries(options.formData)
|
|
90
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
91
|
+
.forEach(([key, value]) => {
|
|
92
|
+
if (Array.isArray(value)) {
|
|
93
|
+
value.forEach(v => process(key, v));
|
|
94
|
+
} else {
|
|
95
|
+
process(key, value);
|
|
96
|
+
}
|
|
97
|
+
});
|
|
98
|
+
|
|
99
|
+
return formData;
|
|
100
|
+
}
|
|
101
|
+
return undefined;
|
|
102
|
+
};
|
|
103
|
+
|
|
104
|
+
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>;
|
|
105
|
+
|
|
106
|
+
export const resolve = async <T>(options: ApiRequestOptions, resolver?: T | Resolver<T>): Promise<T | undefined> => {
|
|
107
|
+
if (typeof resolver === 'function') {
|
|
108
|
+
return (resolver as Resolver<T>)(options);
|
|
109
|
+
}
|
|
110
|
+
return resolver;
|
|
111
|
+
};
|
|
112
|
+
|
|
113
|
+
export const getHeaders = async (config: OpenAPIConfig, options: ApiRequestOptions): Promise<Headers> => {
|
|
114
|
+
const [token, username, password, additionalHeaders] = await Promise.all([
|
|
115
|
+
resolve(options, config.TOKEN),
|
|
116
|
+
resolve(options, config.USERNAME),
|
|
117
|
+
resolve(options, config.PASSWORD),
|
|
118
|
+
resolve(options, config.HEADERS),
|
|
119
|
+
]);
|
|
120
|
+
|
|
121
|
+
const headers = Object.entries({
|
|
122
|
+
Accept: 'application/json',
|
|
123
|
+
...additionalHeaders,
|
|
124
|
+
...options.headers,
|
|
125
|
+
})
|
|
126
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
127
|
+
.reduce((headers, [key, value]) => ({
|
|
128
|
+
...headers,
|
|
129
|
+
[key]: String(value),
|
|
130
|
+
}), {} as Record<string, string>);
|
|
131
|
+
|
|
132
|
+
if (isStringWithValue(token)) {
|
|
133
|
+
headers['Authorization'] = `Bearer ${token}`;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
if (isStringWithValue(username) && isStringWithValue(password)) {
|
|
137
|
+
const credentials = base64(`${username}:${password}`);
|
|
138
|
+
headers['Authorization'] = `Basic ${credentials}`;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
if (options.body !== undefined) {
|
|
142
|
+
if (options.mediaType) {
|
|
143
|
+
headers['Content-Type'] = options.mediaType;
|
|
144
|
+
} else if (isBlob(options.body)) {
|
|
145
|
+
headers['Content-Type'] = options.body.type || 'application/octet-stream';
|
|
146
|
+
} else if (isString(options.body)) {
|
|
147
|
+
headers['Content-Type'] = 'text/plain';
|
|
148
|
+
} else if (!isFormData(options.body)) {
|
|
149
|
+
headers['Content-Type'] = 'application/json';
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
return new Headers(headers);
|
|
154
|
+
};
|
|
155
|
+
|
|
156
|
+
export const getRequestBody = (options: ApiRequestOptions): unknown => {
|
|
157
|
+
if (options.body !== undefined) {
|
|
158
|
+
if (options.mediaType?.includes('application/json') || options.mediaType?.includes('+json')) {
|
|
159
|
+
return JSON.stringify(options.body);
|
|
160
|
+
} else if (isString(options.body) || isBlob(options.body) || isFormData(options.body)) {
|
|
161
|
+
return options.body;
|
|
162
|
+
} else {
|
|
163
|
+
return JSON.stringify(options.body);
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
return undefined;
|
|
167
|
+
};
|
|
168
|
+
|
|
169
|
+
export const sendRequest = async (
|
|
170
|
+
config: OpenAPIConfig,
|
|
171
|
+
options: ApiRequestOptions,
|
|
172
|
+
url: string,
|
|
173
|
+
body: any,
|
|
174
|
+
formData: FormData | undefined,
|
|
175
|
+
headers: Headers,
|
|
176
|
+
onCancel: OnCancel
|
|
177
|
+
): Promise<Response> => {
|
|
178
|
+
const controller = new AbortController();
|
|
179
|
+
|
|
180
|
+
let request: RequestInit = {
|
|
181
|
+
headers,
|
|
182
|
+
body: body ?? formData,
|
|
183
|
+
method: options.method,
|
|
184
|
+
signal: controller.signal,
|
|
185
|
+
};
|
|
186
|
+
|
|
187
|
+
if (config.WITH_CREDENTIALS) {
|
|
188
|
+
request.credentials = config.CREDENTIALS;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
for (const fn of config.interceptors.request._fns) {
|
|
192
|
+
request = await fn(request);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
onCancel(() => controller.abort());
|
|
196
|
+
|
|
197
|
+
return await fetch(url, request);
|
|
198
|
+
};
|
|
199
|
+
|
|
200
|
+
export const getResponseHeader = (response: Response, responseHeader?: string): string | undefined => {
|
|
201
|
+
if (responseHeader) {
|
|
202
|
+
const content = response.headers.get(responseHeader);
|
|
203
|
+
if (isString(content)) {
|
|
204
|
+
return content;
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
return undefined;
|
|
208
|
+
};
|
|
209
|
+
|
|
210
|
+
export const getResponseBody = async (response: Response): Promise<unknown> => {
|
|
211
|
+
if (response.status !== 204) {
|
|
212
|
+
try {
|
|
213
|
+
const contentType = response.headers.get('Content-Type');
|
|
214
|
+
if (contentType) {
|
|
215
|
+
const binaryTypes = ['application/octet-stream', 'application/pdf', 'application/zip', 'audio/', 'image/', 'video/'];
|
|
216
|
+
if (contentType.includes('application/json') || contentType.includes('+json')) {
|
|
217
|
+
return await response.json();
|
|
218
|
+
} else if (binaryTypes.some(type => contentType.includes(type))) {
|
|
219
|
+
return await response.blob();
|
|
220
|
+
} else if (contentType.includes('multipart/form-data')) {
|
|
221
|
+
return await response.formData();
|
|
222
|
+
} else if (contentType.includes('text/')) {
|
|
223
|
+
return await response.text();
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
} catch (error) {
|
|
227
|
+
console.error(error);
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
return undefined;
|
|
231
|
+
};
|
|
232
|
+
|
|
233
|
+
export const catchErrorCodes = (options: ApiRequestOptions, result: ApiResult): void => {
|
|
234
|
+
const errors: Record<number, string> = {
|
|
235
|
+
400: 'Bad Request',
|
|
236
|
+
401: 'Unauthorized',
|
|
237
|
+
402: 'Payment Required',
|
|
238
|
+
403: 'Forbidden',
|
|
239
|
+
404: 'Not Found',
|
|
240
|
+
405: 'Method Not Allowed',
|
|
241
|
+
406: 'Not Acceptable',
|
|
242
|
+
407: 'Proxy Authentication Required',
|
|
243
|
+
408: 'Request Timeout',
|
|
244
|
+
409: 'Conflict',
|
|
245
|
+
410: 'Gone',
|
|
246
|
+
411: 'Length Required',
|
|
247
|
+
412: 'Precondition Failed',
|
|
248
|
+
413: 'Payload Too Large',
|
|
249
|
+
414: 'URI Too Long',
|
|
250
|
+
415: 'Unsupported Media Type',
|
|
251
|
+
416: 'Range Not Satisfiable',
|
|
252
|
+
417: 'Expectation Failed',
|
|
253
|
+
418: 'Im a teapot',
|
|
254
|
+
421: 'Misdirected Request',
|
|
255
|
+
422: 'Unprocessable Content',
|
|
256
|
+
423: 'Locked',
|
|
257
|
+
424: 'Failed Dependency',
|
|
258
|
+
425: 'Too Early',
|
|
259
|
+
426: 'Upgrade Required',
|
|
260
|
+
428: 'Precondition Required',
|
|
261
|
+
429: 'Too Many Requests',
|
|
262
|
+
431: 'Request Header Fields Too Large',
|
|
263
|
+
451: 'Unavailable For Legal Reasons',
|
|
264
|
+
500: 'Internal Server Error',
|
|
265
|
+
501: 'Not Implemented',
|
|
266
|
+
502: 'Bad Gateway',
|
|
267
|
+
503: 'Service Unavailable',
|
|
268
|
+
504: 'Gateway Timeout',
|
|
269
|
+
505: 'HTTP Version Not Supported',
|
|
270
|
+
506: 'Variant Also Negotiates',
|
|
271
|
+
507: 'Insufficient Storage',
|
|
272
|
+
508: 'Loop Detected',
|
|
273
|
+
510: 'Not Extended',
|
|
274
|
+
511: 'Network Authentication Required',
|
|
275
|
+
...options.errors,
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
const error = errors[result.status];
|
|
279
|
+
if (error) {
|
|
280
|
+
throw new ApiError(options, result, error);
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
if (!result.ok) {
|
|
284
|
+
const errorStatus = result.status ?? 'unknown';
|
|
285
|
+
const errorStatusText = result.statusText ?? 'unknown';
|
|
286
|
+
const errorBody = (() => {
|
|
287
|
+
try {
|
|
288
|
+
return JSON.stringify(result.body, null, 2);
|
|
289
|
+
} catch (e) {
|
|
290
|
+
return undefined;
|
|
291
|
+
}
|
|
292
|
+
})();
|
|
293
|
+
|
|
294
|
+
throw new ApiError(options, result,
|
|
295
|
+
`Generic Error: status: ${errorStatus}; status text: ${errorStatusText}; body: ${errorBody}`
|
|
296
|
+
);
|
|
297
|
+
}
|
|
298
|
+
};
|
|
299
|
+
|
|
300
|
+
/**
|
|
301
|
+
* Request method
|
|
302
|
+
* @param config The OpenAPI configuration object
|
|
303
|
+
* @param options The request options from the service
|
|
304
|
+
* @returns CancelablePromise<T>
|
|
305
|
+
* @throws ApiError
|
|
306
|
+
*/
|
|
307
|
+
export const request = <T>(config: OpenAPIConfig, options: ApiRequestOptions): CancelablePromise<T> => {
|
|
308
|
+
return new CancelablePromise(async (resolve, reject, onCancel) => {
|
|
309
|
+
try {
|
|
310
|
+
const url = getUrl(config, options);
|
|
311
|
+
const formData = getFormData(options);
|
|
312
|
+
const body = getRequestBody(options);
|
|
313
|
+
const headers = await getHeaders(config, options);
|
|
314
|
+
|
|
315
|
+
if (!onCancel.isCancelled) {
|
|
316
|
+
let response = await sendRequest(config, options, url, body, formData, headers, onCancel);
|
|
317
|
+
|
|
318
|
+
for (const fn of config.interceptors.response._fns) {
|
|
319
|
+
response = await fn(response);
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
const responseBody = await getResponseBody(response);
|
|
323
|
+
const responseHeader = getResponseHeader(response, options.responseHeader);
|
|
324
|
+
|
|
325
|
+
const result: ApiResult = {
|
|
326
|
+
url,
|
|
327
|
+
ok: response.ok,
|
|
328
|
+
status: response.status,
|
|
329
|
+
statusText: response.statusText,
|
|
330
|
+
body: responseHeader ?? responseBody,
|
|
331
|
+
};
|
|
332
|
+
|
|
333
|
+
catchErrorCodes(options, result);
|
|
334
|
+
|
|
335
|
+
resolve(result.body);
|
|
336
|
+
}
|
|
337
|
+
} catch (error) {
|
|
338
|
+
reject(error);
|
|
339
|
+
}
|
|
340
|
+
});
|
|
341
341
|
};
|