From 92a37a773a53d958881e8f9c3697be6ccfb37c42 Mon Sep 17 00:00:00 2001 From: Per Kops Date: Thu, 12 Dec 2024 13:28:07 +0100 Subject: [PATCH 1/5] style: use collection-expression in ApiOperationExtractor --- .../Extractors/ApiOperationExtractor.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Atc.Rest.ApiGenerator.OpenApi/Extractors/ApiOperationExtractor.cs b/src/Atc.Rest.ApiGenerator.OpenApi/Extractors/ApiOperationExtractor.cs index e78e77358..438f5518e 100644 --- a/src/Atc.Rest.ApiGenerator.OpenApi/Extractors/ApiOperationExtractor.cs +++ b/src/Atc.Rest.ApiGenerator.OpenApi/Extractors/ApiOperationExtractor.cs @@ -5,7 +5,7 @@ namespace Atc.Rest.ApiGenerator.OpenApi.Extractors; public sealed class ApiOperationExtractor : IApiOperationExtractor { - public static readonly char[] ModelNameSeparators = { ' ', '-', '_', '.' }; + public static readonly char[] ModelNameSeparators = [' ', '-', '_', '.']; public IList Extract( OpenApiDocument apiDocument) From b5ae8a689ca8c772ada7d2cd235d0f8edf10d22e Mon Sep 17 00:00:00 2001 From: Per Kops Date: Thu, 12 Dec 2024 13:28:38 +0100 Subject: [PATCH 2/5] chore: rename IsSchemaEnumAndUseJsonString to IsSchemaEnumAndUsesJsonString in OpenApiParameterExtensions --- .../Extensions/OpenApiDocumentExtensions.cs | 4 ++-- .../Extensions/OpenApiParameterExtensions.cs | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiDocumentExtensions.cs b/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiDocumentExtensions.cs index 1e07398dd..91be6b2b9 100644 --- a/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiDocumentExtensions.cs +++ b/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiDocumentExtensions.cs @@ -262,7 +262,7 @@ public static bool IsUsingRequiredForSystemTextJsonSerializationAndSystemRuntime foreach (var apiParameter in apiPathPair.Value.Parameters) { - if (apiParameter.IsSchemaEnumAndUseJsonString()) + if (apiParameter.IsSchemaEnumAndUsesJsonString()) { return true; } @@ -270,7 +270,7 @@ public static bool IsUsingRequiredForSystemTextJsonSerializationAndSystemRuntime foreach (var apiParameter in apiOperationPair.Value.Parameters) { - if (apiParameter.IsSchemaEnumAndUseJsonString()) + if (apiParameter.IsSchemaEnumAndUsesJsonString()) { return true; } diff --git a/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiParameterExtensions.cs b/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiParameterExtensions.cs index f4304def9..6cfd4ab12 100644 --- a/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiParameterExtensions.cs +++ b/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiParameterExtensions.cs @@ -2,7 +2,8 @@ namespace Atc.Rest.ApiGenerator.OpenApi.Extensions; public static class OpenApiParameterExtensions { - public static bool IsSchemaEnumAndUseJsonString(this OpenApiParameter apiParameter) + public static bool IsSchemaEnumAndUsesJsonString( + this OpenApiParameter apiParameter) { if (apiParameter.Schema.IsSchemaEnum()) { From 73360b2ef7eaf762783b7613cdeadf82664e66d8 Mon Sep 17 00:00:00 2001 From: Per Kops Date: Thu, 12 Dec 2024 13:29:04 +0100 Subject: [PATCH 3/5] feat: add ContainsEnumInSchemaOrProperties in OpenApiParameterExtensions --- .../Extensions/OpenApiParameterExtensions.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiParameterExtensions.cs b/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiParameterExtensions.cs index 6cfd4ab12..0543afc80 100644 --- a/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiParameterExtensions.cs +++ b/src/Atc.Rest.ApiGenerator.OpenApi/Extensions/OpenApiParameterExtensions.cs @@ -25,6 +25,13 @@ public static bool IsSchemaEnumAndUsesJsonString( return false; } + public static bool ContainsEnumInSchemaOrProperties( + this OpenApiParameter apiParameter) + => apiParameter.Schema.IsSchemaEnumOrPropertyEnum() || + apiParameter.Schema.AllOf.Any(allOfSchema => allOfSchema.IsSchemaEnumOrPropertyEnum()) || + apiParameter.Schema.OneOf.Any(oneOfSchema => oneOfSchema.IsSchemaEnumOrPropertyEnum()) || + apiParameter.Schema.AnyOf.Any(anyOfSchema => anyOfSchema.IsSchemaEnumOrPropertyEnum()); + public static CodeDocumentationTags ExtractDocumentationTags( this OpenApiParameter apiParameter) { From 1e59aaf8e72a137056d65a68853e4e16f9d018fc Mon Sep 17 00:00:00 2001 From: Per Kops Date: Thu, 12 Dec 2024 13:31:40 +0100 Subject: [PATCH 4/5] fix: ensure proper generation of csharp client for default values on enums --- ...neratorClientParameterParametersFactory.cs | 20 +++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/src/Atc.Rest.ApiGenerator.Framework/Factories/Parameters/Client/ContentGeneratorClientParameterParametersFactory.cs b/src/Atc.Rest.ApiGenerator.Framework/Factories/Parameters/Client/ContentGeneratorClientParameterParametersFactory.cs index 043c73422..e13227c0e 100644 --- a/src/Atc.Rest.ApiGenerator.Framework/Factories/Parameters/Client/ContentGeneratorClientParameterParametersFactory.cs +++ b/src/Atc.Rest.ApiGenerator.Framework/Factories/Parameters/Client/ContentGeneratorClientParameterParametersFactory.cs @@ -37,6 +37,8 @@ private static void AppendParameters( { var useListForDataType = openApiParameter.Schema.IsTypeArray(); + var parameterName = openApiParameter.Name.EnsureValidFormattedPropertyName(); + var dataType = useListForDataType ? openApiParameter.Schema.Items.GetDataType() : openApiParameter.Schema.GetDataType(); @@ -47,9 +49,19 @@ private static void AppendParameters( if (parameters.FirstOrDefault(x => x.Name == openApiParameter.Name) is null) { + var defaultValueInitializer = openApiParameter.Schema.GetDefaultValueAsString(); + + if (!string.IsNullOrEmpty(defaultValueInitializer) && + openApiParameter.ContainsEnumInSchemaOrProperties()) + { + defaultValueInitializer = dataType.Equals(parameterName, StringComparison.Ordinal) + ? $"{ContentGeneratorConstants.Contracts}.{dataType}.{defaultValueInitializer.PascalCase(ApiOperationExtractor.ModelNameSeparators, removeSeparators: true)}" + : $"{dataType}.{defaultValueInitializer.PascalCase(ApiOperationExtractor.ModelNameSeparators, removeSeparators: true)}"; + } + parameters.Add(new ContentGeneratorClientParameterParametersProperty( openApiParameter.Name, - openApiParameter.Name.EnsureValidFormattedPropertyName(), + parameterName, openApiParameter.ExtractDocumentationTags(), dataType, isSimpleType, @@ -57,7 +69,7 @@ private static void AppendParameters( GetIsNullable(openApiParameter, useListForDataType), openApiParameter.Required, GetAdditionalValidationAttributes(openApiParameter), - openApiParameter.Schema.GetDefaultValueAsString())); + defaultValueInitializer)); } } } @@ -94,7 +106,7 @@ private static void AppendParametersFromBody( var requestBodyType = "string?"; if (requestSchema.Reference is not null) { - requestBodyType = requestSchema.Reference.Id.EnsureFirstCharacterToUpper(); + requestBodyType = requestSchema.Reference.Id.PascalCase(ApiOperationExtractor.ModelNameSeparators, removeSeparators: true); } else if (isFormatTypeOfBinary) { @@ -106,7 +118,7 @@ private static void AppendParametersFromBody( } else if (requestSchema.Items is not null) { - requestBodyType = requestSchema.Items.Reference.Id.EnsureFirstCharacterToUpper(); + requestBodyType = requestSchema.Items.Reference.Id.PascalCase(ApiOperationExtractor.ModelNameSeparators, removeSeparators: true); } parameters.Add(new ContentGeneratorClientParameterParametersProperty( From 242b90dbd7ae2ccbb1bcf73bae4bc66ea04b7833 Mon Sep 17 00:00:00 2001 From: Per Kops Date: Fri, 13 Dec 2024 10:53:26 +0100 Subject: [PATCH 5/5] test: update monta client test --- .../Scenarios/Monta/Monta.yaml | 15326 +++++++++++----- .../ChargeAuthToken.verified.cs | 3 + .../CreateChargeAuthToken.verified.cs | 3 + .../ChargePointIntegration.verified.cs | 6 + .../ChargePointModel.verified.cs | 3 + .../ChargePointStatisticsDto.verified.cs | 68 + .../Performance.verified.cs | 30 + ...hargePointStatisticsParameters.verified.cs | 32 + .../GetSiteStatisticsParameters.verified.cs | 32 + .../ChargePointStatistics/States.verified.cs | 36 + .../TimePeriod.verified.cs | 30 + .../ChargePointOcppLog.verified.cs | 30 + .../CreateChargePoint.verified.cs | 6 + .../ChargePoints/MapResult.verified.cs | 9 + .../MapResultChargePoint.verified.cs | 6 + .../ChargePoints/MapResultCluster.verified.cs | 3 + .../ChargePoints/MapResultSite.verified.cs | 3 + ...MontaPageChargePointOcppLogDto.verified.cs | 24 + .../ChargePoints/PatchChargePoint.verified.cs | 13 +- ...tChargePointOcppLogsParameters.verified.cs | 37 + .../GetChargePointsParameters.verified.cs | 10 +- .../RebootChargePointParameters.verified.cs | 23 + .../UnlockChargePointParameters.verified.cs | 23 + .../Charges/BreakdownSummary.verified.cs | 7 +- .../Contracts/Charges/Charge.verified.cs | 40 +- .../Charges/ChargeBreakdown.verified.cs | 6 + .../Charges/ChargesInsight.verified.cs | 11 +- .../Charges/ChargesInsightEntry.verified.cs | 6 + .../Contracts/Charges/Component.verified.cs | 9 + .../Currency11.verified.cs} | 22 +- .../Contracts/Charges/Currency5.verified.cs | 35 + .../Contracts/Charges/Currency9.verified.cs | 35 + .../Charges/DetailedBreakdown.verified.cs | 8 +- .../Charges/GenericPaymentSession.verified.cs | 7 +- .../Contracts/Charges/PatchCharge.verified.cs | 5 +- .../PatchGenericPaymentSession.verified.cs | 50 + .../Charges/PublicChargePoint.verified.cs | 3 + .../PublicUser3.verified.cs} | 6 +- .../GetChargesParameters.verified.cs | 6 +- .../Charges/StartChargeRequest.verified.cs | 12 +- .../CountryAreas/CountryArea.verified.cs | 3 + .../MontaPageCurrencyDto.verified.cs | 2 +- ...ightByChargeAuthTokenReportDto.verified.cs | 41 + ...eAuthTokenReportDtoConsumption.verified.cs | 74 + ...InsightDriverMemberCostsReport.verified.cs | 42 + ...emberCostsReportDtoConsumption.verified.cs | 80 + ...DtoConsumptionCountryBreakdown.verified.cs | 59 + ...ightByChargeAuthTokenReportDto.verified.cs | 24 + ...ightDriverMemberCostsReportDto.verified.cs | 24 + ...hargeAuthTokenReportParameters.verified.cs | 42 + ...ChargesChargerReportParameters.verified.cs | 13 +- ...verMemberCostsReportParameters.verified.cs | 44 + ...sChargesDriverReportParameters.verified.cs | 15 +- .../InstallerJobs/InstallerJob.verified.cs | 3 + .../Contracts/Invoices/InvoiceDto.verified.cs | 87 + .../Invoices/MontaPageInvoiceDto.verified.cs | 24 + .../GetInvoice1Parameters.verified.cs | 23 + .../GetInvoiceParameters.verified.cs | 36 + .../MontaPageNestedTeamDto.verified.cs | 24 + .../NestedTeams/NestedTeam.verified.cs | 89 + .../NestedTeams/NestedTeamInvite.verified.cs | 52 + .../NestedTeams/PatchNestedTeam.verified.cs | 34 + .../NestedTeams/PriceGroup1.verified.cs | 29 + .../NestedTeams/PublicTeam.verified.cs | 33 + .../NestedTeams/PublicUser.verified.cs | 38 + .../AcceptInviteParameters.verified.cs | 24 + .../DeleteNestedTeamParameters.verified.cs | 24 + .../GetNestedTeamParameters.verified.cs | 24 + .../GetNestedTeamsParameters.verified.cs | 34 + .../InviteParameters.verified.cs | 23 + .../RejectInviteParameters.verified.cs | 24 + .../UpdateNestedTeamParameters.verified.cs | 27 + .../GetOperatorsParameters.verified.cs | 10 +- .../PaymentTerminal.verified.cs | 3 + .../Contracts/Plans/Currency1.verified.cs | 35 + .../Contracts/Plans/Plan.verified.cs | 15 + .../Contracts/Plans/PlanPrice.verified.cs | 5 +- .../CreateAdditionalPricingDto.verified.cs | 11 +- .../CreateOrUpdatePriceGroupDto.verified.cs | 6 + .../CreateOrUpdatePricingDto.verified.cs | 3 + .../Contracts/Prices/Currency17.verified.cs | 35 + .../Prices/PricesForecast.verified.cs | 11 +- .../Reports/MontaPageReportDto.verified.cs | 24 + .../Contracts/Reports/ReasonDto.verified.cs | 48 + .../Contracts/Reports/ReportDto.verified.cs | 135 + .../GetReportParameters.verified.cs | 23 + .../GetReportsParameters.verified.cs | 40 + .../Contracts/Sites/CreateSite.verified.cs | 6 + .../Contracts/Sites/PatchSite.verified.cs | 6 + .../GetSitesParameters.verified.cs | 26 +- .../Contracts/Sites/Site.verified.cs | 6 + .../CreateSponsoredChargePointDto.verified.cs | 3 + .../PatchSponsoredChargePoint.verified.cs | 3 + .../PublicUser1.verified.cs | 30 + .../SponsoredChargePoint.verified.cs | 9 + .../SponsoredChargePointData.verified.cs | 11 +- .../Currency3.verified.cs | 35 + .../SubscriptionPurchase.verified.cs | 11 +- .../CreateSubscription.verified.cs | 22 +- .../GetSubscriptionsParameters.verified.cs | 6 +- ...ateTariffPeriodGroupParameters.verified.cs | 2 +- ...ateTariffPeriodGroupParameters.verified.cs | 2 +- .../TariffPeriodGroup1.verified.cs | 41 + .../TariffPeriodGroup2.verified.cs | 33 + .../TariffRecurringPeriod.verified.cs | 6 + ...ecurringPeriodCreateRequestDto.verified.cs | 6 + ...ecurringPeriodUpdateRequestDto.verified.cs | 6 + .../Tariffs/CreateTariffRequest.verified.cs | 6 + .../Contracts/Tariffs/FullTariff.verified.cs | 6 + .../Contracts/Tariffs/TariffDto.verified.cs | 6 + .../Tariffs/UpdateTariffRequest.verified.cs | 6 + .../CreateTeamMemberProfile.verified.cs | 89 + .../MontaPageTeamMemberProfileDto.verified.cs | 24 + .../PatchTeamMemberProfile.verified.cs | 75 + ...eteTeamMemberProfileParameters.verified.cs | 23 + ...GetTeamMemberProfileParameters.verified.cs | 23 + ...etTeamMemberProfilesParameters.verified.cs | 34 + ...ostTeamMemberProfileParameters.verified.cs | 23 + ...ateTeamMemberProfileParameters.verified.cs | 26 + .../TeamMemberProfile.verified.cs | 112 + .../TeamMembers/CreateTeamMember.verified.cs | 25 +- .../MontaPageTeamMemberDto.verified.cs | 2 +- .../TeamMembers/PatchTeamMember.verified.cs | 25 +- ...eamMemberJoinRequestParameters.verified.cs | 23 + .../GetTeamMembersParameters.verified.cs | 2 +- ...Dto.verified.cs => TeamMember.verified.cs} | 45 +- .../Contracts/Teams/CreateTeamDto.verified.cs | 16 +- .../Contracts/Teams/Currency7.verified.cs | 35 + .../Contracts/Teams/PatchTeam.verified.cs | 3 + .../FreezeTeamParameters.verified.cs | 26 + .../GetTeamsParameters.verified.cs | 12 +- .../UnfreezeTeamParameters.verified.cs | 23 + .../Contracts/Teams/Team.verified.cs | 33 +- .../Teams/TeamDtoTeamCategoryDto.verified.cs | 30 + .../Teams/UpdateTeamStateDto.verified.cs | 23 + .../Users/MontaPageUserDto.verified.cs | 24 + .../GetUserParameters.verified.cs | 23 + .../GetUsersParameters.verified.cs | 49 + .../Contracts/Users/User.verified.cs | 79 + .../WalletTransactions/Currency13.verified.cs | 35 + .../WalletTransactions/Currency14.verified.cs | 35 + .../OperatorAdjustmentTransaction.verified.cs | 12 +- ...WalletTransactions1Parameters.verified.cs} | 12 +- ...etWalletTransactionsParameters.verified.cs | 4 +- .../WalletTransaction.verified.cs | 41 +- .../Contracts/Wallets/Wallet.verified.cs | 3 + .../GetWebhookEntriesParameters.verified.cs | 5 +- .../Webhooks/WebhookConfig.verified.cs | 7 +- .../Webhooks/WebhookEntry.verified.cs | 13 + .../Webhooks/WebhookEntryPayload.verified.cs | 13 +- .../ComponentTypeDto.verified.cs | 3 + .../ElectricCurrentType.verified.cs | 3 + .../SubscriptionCustomerType.verified.cs | 16 +- .../TeamMemberAccess.verified.cs | 3 - .../TeamMemberAccess1.verified.cs | 24 + .../TeamMemberState.verified.cs | 9 +- .../TeamMemberState1.verified.cs | 36 + .../TeamMemberState3.verified.cs | 36 + .../WebhookEntryEventType.verified.cs | 12 +- .../WebhookEntryPayloadEntityType.verified.cs | 9 + .../_Shared/AdditionalPricing.verified.cs | 13 +- .../Contracts/_Shared/ChargePoint.verified.cs | 37 +- .../Contracts/_Shared/Consumer.verified.cs | 10 +- .../CreatedOrUpdateAddress.verified.cs | 2 - .../Contracts/_Shared/Currency.verified.cs | 24 +- .../CurrencyDto.verified.cs} | 8 +- .../Contracts/_Shared/Location.verified.cs | 6 + .../Contracts/_Shared/Money.verified.cs | 3 + .../Contracts/_Shared/Pageable.verified.cs | 23 + .../Contracts/_Shared/PriceGroup.verified.cs | 6 + .../_Shared/PriceGroupTag.verified.cs | 3 + .../Contracts/_Shared/Pricing.verified.cs | 17 +- .../Contracts/_Shared/SimCard.verified.cs | 28 + .../_Shared/Subscription.verified.cs | 9 + .../BlockChargeAuthTokenEndpoint.verified.cs | 1 + ...kChargeAuthTokenEndpointResult.verified.cs | 8 + .../CreateChargeAuthTokenEndpoint.verified.cs | 1 + ...eChargeAuthTokenEndpointResult.verified.cs | 8 + .../GetChargeAuthTokensEndpoint.verified.cs | 2 + ...ChargeAuthTokensEndpointResult.verified.cs | 16 + ...kChargeAuthTokenEndpointResult.verified.cs | 4 + ...eChargeAuthTokenEndpointResult.verified.cs | 4 + ...ChargeAuthTokensEndpointResult.verified.cs | 8 + ...hChargeAuthTokenEndpointResult.verified.cs | 4 + ...kChargeAuthTokenEndpointResult.verified.cs | 4 + .../PatchChargeAuthTokenEndpoint.verified.cs | 1 + ...hChargeAuthTokenEndpointResult.verified.cs | 8 + ...UnblockChargeAuthTokenEndpoint.verified.cs | 1 + ...kChargeAuthTokenEndpointResult.verified.cs | 8 + .../GetChargePointBrandsEndpoint.verified.cs | 2 + ...hargePointBrandsEndpointResult.verified.cs | 16 + ...hargePointBrandsEndpointResult.verified.cs | 8 + .../GetConnectorsEndpoint.verified.cs | 2 + .../GetConnectorsEndpointResult.verified.cs | 16 + .../IGetConnectorsEndpointResult.verified.cs | 8 + ...hargePointIntegrationsEndpoint.verified.cs | 2 + ...ointIntegrationsEndpointResult.verified.cs | 16 + ...ointIntegrationsEndpointResult.verified.cs | 8 + ...PointIntegrationEndpointResult.verified.cs | 4 + ...ChargePointIntegrationEndpoint.verified.cs | 1 + ...PointIntegrationEndpointResult.verified.cs | 8 + .../GetChargePointModelsEndpoint.verified.cs | 2 + ...hargePointModelsEndpointResult.verified.cs | 16 + ...hargePointModelsEndpointResult.verified.cs | 8 + ...tChargePointStatisticsEndpoint.verified.cs | 51 + ...ePointStatisticsEndpointResult.verified.cs | 61 + .../GetSiteStatisticsEndpoint.verified.cs | 51 + ...etSiteStatisticsEndpointResult.verified.cs | 61 + ...tChargePointStatisticsEndpoint.verified.cs | 27 + ...ePointStatisticsEndpointResult.verified.cs | 37 + .../IGetSiteStatisticsEndpoint.verified.cs | 27 + ...etSiteStatisticsEndpointResult.verified.cs | 37 + .../DeleteChargePointEndpoint.verified.cs | 1 + ...eleteChargePointEndpointResult.verified.cs | 8 + .../GetChargePointMapEndpoint.verified.cs | 2 + ...etChargePointMapEndpointResult.verified.cs | 16 + ...GetChargePointOcppLogsEndpoint.verified.cs | 53 + ...rgePointOcppLogsEndpointResult.verified.cs | 61 + .../GetChargePointsEndpoint.verified.cs | 5 + .../GetChargePointsEndpointResult.verified.cs | 16 + ...eleteChargePointEndpointResult.verified.cs | 4 + ...etChargePointMapEndpointResult.verified.cs | 8 + ...GetChargePointOcppLogsEndpoint.verified.cs | 27 + ...rgePointOcppLogsEndpointResult.verified.cs | 37 + ...IGetChargePointsEndpointResult.verified.cs | 8 + ...PatchChargePointEndpointResult.verified.cs | 4 + ...IPostChargePointEndpointResult.verified.cs | 4 + .../IRebootChargePointEndpoint.verified.cs | 27 + ...ebootChargePointEndpointResult.verified.cs | 37 + .../IUnlockChargePointEndpoint.verified.cs | 27 + ...nlockChargePointEndpointResult.verified.cs | 37 + .../PatchChargePointEndpoint.verified.cs | 1 + ...PatchChargePointEndpointResult.verified.cs | 8 + .../PostChargePointEndpoint.verified.cs | 1 + .../PostChargePointEndpointResult.verified.cs | 8 + .../RebootChargePointEndpoint.verified.cs | 49 + ...ebootChargePointEndpointResult.verified.cs | 61 + .../UnlockChargePointEndpoint.verified.cs | 49 + ...nlockChargePointEndpointResult.verified.cs | 61 + .../GetChargeBreakdownEndpoint.verified.cs | 1 + ...tChargeBreakdownEndpointResult.verified.cs | 8 + .../Charges/GetChargesEndpoint.verified.cs | 3 + .../GetChargesEndpointResult.verified.cs | 16 + ...tChargeBreakdownEndpointResult.verified.cs | 4 + .../IGetChargesEndpointResult.verified.cs | 8 + .../IPatchChargeEndpointResult.verified.cs | 4 + .../IStartChargeEndpointResult.verified.cs | 4 + .../Charges/PatchChargeEndpoint.verified.cs | 1 + .../PatchChargeEndpointResult.verified.cs | 8 + .../Charges/StartChargeEndpoint.verified.cs | 1 + .../StartChargeEndpointResult.verified.cs | 8 + .../GetCurrentConsumerEndpoint.verified.cs | 2 + ...tCurrentConsumerEndpointResult.verified.cs | 16 + ...tCurrentConsumerEndpointResult.verified.cs | 8 + .../GetCountriesEndpoint.verified.cs | 2 + .../GetCountriesEndpointResult.verified.cs | 16 + .../Countries/GetCountryEndpoint.verified.cs | 2 + .../GetCountryEndpointResult.verified.cs | 16 + .../IGetCountriesEndpointResult.verified.cs | 8 + .../IGetCountryEndpointResult.verified.cs | 8 + .../GetCountriesAreasEndpoint.verified.cs | 1 + ...etCountriesAreasEndpointResult.verified.cs | 8 + .../GetCountryAreaEndpoint.verified.cs | 1 + .../GetCountryAreaEndpointResult.verified.cs | 8 + ...etCountriesAreasEndpointResult.verified.cs | 4 + .../IGetCountryAreaEndpointResult.verified.cs | 4 + .../GetCurrenciesEndpoint.verified.cs | 2 + .../GetCurrenciesEndpointResult.verified.cs | 16 + .../GetCurrencyEndpoint.verified.cs | 2 +- .../GetCurrencyEndpointResult.verified.cs | 4 +- .../IGetCurrenciesEndpointResult.verified.cs | 8 + .../IGetCurrencyEndpointResult.verified.cs | 2 +- ...sChargeAuthTokenReportEndpoint.verified.cs | 54 + ...eAuthTokenReportEndpointResult.verified.cs | 61 + ...tsChargesChargerReportEndpoint.verified.cs | 4 + ...gesChargerReportEndpointResult.verified.cs | 16 + ...riverMemberCostsReportEndpoint.verified.cs | 55 + ...emberCostsReportEndpointResult.verified.cs | 61 + ...htsChargesDriverReportEndpoint.verified.cs | 4 + ...rgesDriverReportEndpointResult.verified.cs | 16 + ...sChargeAuthTokenReportEndpoint.verified.cs | 27 + ...eAuthTokenReportEndpointResult.verified.cs | 37 + ...gesChargerReportEndpointResult.verified.cs | 8 + ...riverMemberCostsReportEndpoint.verified.cs | 27 + ...emberCostsReportEndpointResult.verified.cs | 37 + ...rgesDriverReportEndpointResult.verified.cs | 8 + .../DeleteInstallerJobEndpoint.verified.cs | 1 + ...leteInstallerJobEndpointResult.verified.cs | 8 + .../GetInstallerJobsEndpoint.verified.cs | 2 + ...GetInstallerJobsEndpointResult.verified.cs | 16 + ...leteInstallerJobEndpointResult.verified.cs | 4 + ...GetInstallerJobsEndpointResult.verified.cs | 8 + ...PostInstallerJobEndpointResult.verified.cs | 4 + .../PostInstallerJobEndpoint.verified.cs | 1 + ...PostInstallerJobEndpointResult.verified.cs | 8 + .../Invoices/GetInvoice1Endpoint.verified.cs | 49 + .../GetInvoice1EndpointResult.verified.cs | 61 + .../Invoices/GetInvoiceEndpoint.verified.cs | 52 + .../GetInvoiceEndpointResult.verified.cs | 61 + .../IGetInvoice1Endpoint.verified.cs | 27 + .../IGetInvoice1EndpointResult.verified.cs | 37 + .../IGetInvoiceEndpoint.verified.cs | 27 + .../IGetInvoiceEndpointResult.verified.cs | 37 + .../AcceptInviteEndpoint.verified.cs | 49 + .../AcceptInviteEndpointResult.verified.cs | 61 + .../DeleteNestedTeamEndpoint.verified.cs | 49 + ...DeleteNestedTeamEndpointResult.verified.cs | 61 + .../GetNestedTeamEndpoint.verified.cs | 49 + .../GetNestedTeamEndpointResult.verified.cs | 61 + .../GetNestedTeamsEndpoint.verified.cs | 52 + .../GetNestedTeamsEndpointResult.verified.cs | 61 + .../IAcceptInviteEndpoint.verified.cs | 27 + .../IAcceptInviteEndpointResult.verified.cs | 37 + .../IDeleteNestedTeamEndpoint.verified.cs | 27 + ...DeleteNestedTeamEndpointResult.verified.cs | 37 + .../IGetNestedTeamEndpoint.verified.cs | 27 + .../IGetNestedTeamEndpointResult.verified.cs | 37 + .../IGetNestedTeamsEndpoint.verified.cs | 27 + .../IGetNestedTeamsEndpointResult.verified.cs | 37 + .../Interfaces/IInviteEndpoint.verified.cs | 27 + .../IInviteEndpointResult.verified.cs | 37 + .../IRejectInviteEndpoint.verified.cs | 27 + .../IRejectInviteEndpointResult.verified.cs | 37 + .../IUpdateNestedTeamEndpoint.verified.cs | 27 + ...UpdateNestedTeamEndpointResult.verified.cs | 37 + .../InviteEndpoint.verified.cs} | 24 +- .../InviteEndpointResult.verified.cs | 61 + .../RejectInviteEndpoint.verified.cs | 49 + .../RejectInviteEndpointResult.verified.cs | 61 + .../UpdateNestedTeamEndpoint.verified.cs | 50 + ...UpdateNestedTeamEndpointResult.verified.cs | 61 + .../Operators/GetOperatorEndpoint.verified.cs | 1 + .../GetOperatorEndpointResult.verified.cs | 8 + .../GetOperatorsEndpoint.verified.cs | 2 + .../GetOperatorsEndpointResult.verified.cs | 16 + .../IGetOperatorEndpointResult.verified.cs | 4 + .../IGetOperatorsEndpointResult.verified.cs | 8 + .../GetPaymentTerminalsEndpoint.verified.cs | 2 + ...PaymentTerminalsEndpointResult.verified.cs | 16 + ...PaymentTerminalsEndpointResult.verified.cs | 8 + .../Plans/GetPlanEndpoint.verified.cs | 2 + .../Plans/GetPlanEndpointResult.verified.cs | 16 + .../Plans/GetPlansEndpoint.verified.cs | 2 + .../Plans/GetPlansEndpointResult.verified.cs | 16 + .../IGetPlanEndpointResult.verified.cs | 8 + .../IGetPlansEndpointResult.verified.cs | 8 + .../GetPriceGroupTagsEndpoint.verified.cs | 2 + ...etPriceGroupTagsEndpointResult.verified.cs | 16 + ...etPriceGroupTagsEndpointResult.verified.cs | 8 + .../ApplyPriceGroupEndpoint.verified.cs | 1 + .../ApplyPriceGroupEndpointResult.verified.cs | 8 + .../CreatePriceGroupEndpoint.verified.cs | 1 + ...CreatePriceGroupEndpointResult.verified.cs | 8 + .../DeletePriceGroupEndpoint.verified.cs | 1 + ...DeletePriceGroupEndpointResult.verified.cs | 8 + .../GetPriceGroupEndpoint.verified.cs | 2 + .../GetPriceGroupEndpointResult.verified.cs | 16 + .../GetPriceGroupsEndpoint.verified.cs | 2 + .../GetPriceGroupsEndpointResult.verified.cs | 16 + ...IApplyPriceGroupEndpointResult.verified.cs | 4 + ...CreatePriceGroupEndpointResult.verified.cs | 4 + ...DeletePriceGroupEndpointResult.verified.cs | 4 + .../IGetPriceGroupEndpointResult.verified.cs | 8 + .../IGetPriceGroupsEndpointResult.verified.cs | 8 + ...efaultPriceGroupEndpointResult.verified.cs | 4 + ...UpdatePriceGroupEndpointResult.verified.cs | 4 + .../SetDefaultPriceGroupEndpoint.verified.cs | 1 + ...efaultPriceGroupEndpointResult.verified.cs | 8 + .../UpdatePriceGroupEndpoint.verified.cs | 1 + ...UpdatePriceGroupEndpointResult.verified.cs | 8 + .../GetPricesForecastEndpoint.verified.cs | 2 + ...etPricesForecastEndpointResult.verified.cs | 16 + ...etPricesForecastEndpointResult.verified.cs | 8 + .../Reports/GetReportEndpoint.verified.cs | 49 + .../GetReportEndpointResult.verified.cs | 61 + .../Reports/GetReportsEndpoint.verified.cs | 55 + .../GetReportsEndpointResult.verified.cs | 61 + .../Interfaces/IGetReportEndpoint.verified.cs | 27 + .../IGetReportEndpointResult.verified.cs | 37 + .../IGetReportsEndpoint.verified.cs | 27 + .../IGetReportsEndpointResult.verified.cs | 37 + .../Sites/DeleteSiteEndpoint.verified.cs | 1 + .../DeleteSiteEndpointResult.verified.cs | 8 + .../Sites/GetSitesEndpoint.verified.cs | 4 + .../Sites/GetSitesEndpointResult.verified.cs | 16 + .../IDeleteSiteEndpointResult.verified.cs | 4 + .../IGetSitesEndpointResult.verified.cs | 8 + .../IPatchSiteEndpointResult.verified.cs | 4 + .../IPostSiteEndpointResult.verified.cs | 4 + .../Sites/PatchSiteEndpoint.verified.cs | 1 + .../Sites/PatchSiteEndpointResult.verified.cs | 8 + .../Sites/PostSiteEndpoint.verified.cs | 1 + .../Sites/PostSiteEndpointResult.verified.cs | 8 + ...teSponsoredChargePointEndpoint.verified.cs | 1 + ...soredChargePointEndpointResult.verified.cs | 8 + ...tSponsoredChargePointsEndpoint.verified.cs | 2 + ...oredChargePointsEndpointResult.verified.cs | 16 + ...soredChargePointEndpointResult.verified.cs | 4 + ...oredChargePointsEndpointResult.verified.cs | 8 + ...soredChargePointEndpointResult.verified.cs | 8 + ...soredChargePointEndpointResult.verified.cs | 4 + ...chSponsoredChargePointEndpoint.verified.cs | 2 + ...soredChargePointEndpointResult.verified.cs | 16 + ...stSponsoredChargePointEndpoint.verified.cs | 1 + ...soredChargePointEndpointResult.verified.cs | 8 + ...etSubscriptionPurchaseEndpoint.verified.cs | 2 + ...criptionPurchaseEndpointResult.verified.cs | 16 + ...tSubscriptionPurchasesEndpoint.verified.cs | 2 + ...riptionPurchasesEndpointResult.verified.cs | 16 + ...criptionPurchaseEndpointResult.verified.cs | 8 + ...riptionPurchasesEndpointResult.verified.cs | 8 + .../ApproveSubscriptionEndpoint.verified.cs | 2 + ...roveSubscriptionEndpointResult.verified.cs | 16 + .../CreateSubscriptionEndpoint.verified.cs | 2 + ...eateSubscriptionEndpointResult.verified.cs | 16 + .../DeleteSubscriptionEndpoint.verified.cs | 2 + ...leteSubscriptionEndpointResult.verified.cs | 16 + .../GetSubscriptionEndpoint.verified.cs | 2 + .../GetSubscriptionEndpointResult.verified.cs | 16 + .../GetSubscriptionsEndpoint.verified.cs | 4 + ...GetSubscriptionsEndpointResult.verified.cs | 16 + ...roveSubscriptionEndpointResult.verified.cs | 8 + ...eateSubscriptionEndpointResult.verified.cs | 8 + ...leteSubscriptionEndpointResult.verified.cs | 8 + ...IGetSubscriptionEndpointResult.verified.cs | 8 + ...GetSubscriptionsEndpointResult.verified.cs | 8 + ...reateTariffPeriodGroupEndpoint.verified.cs | 2 + ...ariffPeriodGroupEndpointResult.verified.cs | 16 + ...eleteTariffPeriodGroupEndpoint.verified.cs | 2 + ...ariffPeriodGroupEndpointResult.verified.cs | 16 + ...ariffPeriodGroupEndpointResult.verified.cs | 8 + ...ariffPeriodGroupEndpointResult.verified.cs | 8 + ...ariffPeriodGroupEndpointResult.verified.cs | 8 + ...pdateTariffPeriodGroupEndpoint.verified.cs | 2 + ...ariffPeriodGroupEndpointResult.verified.cs | 16 + ...TariffRecurringPeriodsEndpoint.verified.cs | 2 + ...RecurringPeriodsEndpointResult.verified.cs | 16 + ...eTariffRecurringPeriodEndpoint.verified.cs | 2 + ...fRecurringPeriodEndpointResult.verified.cs | 16 + ...tTariffRecurringPeriodEndpoint.verified.cs | 1 + ...fRecurringPeriodEndpointResult.verified.cs | 8 + ...TariffRecurringPeriodsEndpoint.verified.cs | 2 + ...RecurringPeriodsEndpointResult.verified.cs | 16 + ...RecurringPeriodsEndpointResult.verified.cs | 8 + ...fRecurringPeriodEndpointResult.verified.cs | 8 + ...fRecurringPeriodEndpointResult.verified.cs | 4 + ...RecurringPeriodsEndpointResult.verified.cs | 8 + ...RecurringPeriodsEndpointResult.verified.cs | 8 + ...TariffRecurringPeriodsEndpoint.verified.cs | 2 + ...RecurringPeriodsEndpointResult.verified.cs | 16 + .../Tariffs/CreateTariffEndpoint.verified.cs | 2 + .../CreateTariffEndpointResult.verified.cs | 16 + .../ICreateTariffEndpointResult.verified.cs | 8 + .../IUpdateTariffEndpointResult.verified.cs | 8 + .../Tariffs/UpdateTariffEndpoint.verified.cs | 2 + .../UpdateTariffEndpointResult.verified.cs | 16 + ...eleteTeamMemberProfileEndpoint.verified.cs | 49 + ...eamMemberProfileEndpointResult.verified.cs | 61 + .../GetTeamMemberProfileEndpoint.verified.cs | 49 + ...eamMemberProfileEndpointResult.verified.cs | 61 + .../GetTeamMemberProfilesEndpoint.verified.cs | 52 + ...amMemberProfilesEndpointResult.verified.cs | 61 + ...eleteTeamMemberProfileEndpoint.verified.cs | 27 + ...eamMemberProfileEndpointResult.verified.cs | 37 + .../IGetTeamMemberProfileEndpoint.verified.cs | 27 + ...eamMemberProfileEndpointResult.verified.cs | 37 + ...IGetTeamMemberProfilesEndpoint.verified.cs | 27 + ...amMemberProfilesEndpointResult.verified.cs | 37 + ...IPostTeamMemberProfileEndpoint.verified.cs | 27 + ...eamMemberProfileEndpointResult.verified.cs | 37 + ...pdateTeamMemberProfileEndpoint.verified.cs | 27 + ...eamMemberProfileEndpointResult.verified.cs | 37 + .../PostTeamMemberProfileEndpoint.verified.cs | 49 + ...eamMemberProfileEndpointResult.verified.cs | 61 + ...pdateTeamMemberProfileEndpoint.verified.cs | 50 + ...eamMemberProfileEndpointResult.verified.cs | 61 + ...tTeamMemberJoinRequestEndpoint.verified.cs | 49 + ...emberJoinRequestEndpointResult.verified.cs | 61 + .../DeleteTeamMemberEndpoint.verified.cs | 1 + ...DeleteTeamMemberEndpointResult.verified.cs | 8 + .../GetTeamMemberEndpoint.verified.cs | 4 +- .../GetTeamMemberEndpointResult.verified.cs | 20 +- .../GetTeamMembersEndpoint.verified.cs | 2 + .../GetTeamMembersEndpointResult.verified.cs | 16 + ...tTeamMemberJoinRequestEndpoint.verified.cs | 27 + ...emberJoinRequestEndpointResult.verified.cs | 37 + ...DeleteTeamMemberEndpointResult.verified.cs | 4 + .../IGetTeamMemberEndpointResult.verified.cs | 10 +- .../IGetTeamMembersEndpointResult.verified.cs | 8 + ...IPatchTeamMemberEndpointResult.verified.cs | 10 +- .../IPostTeamMemberEndpointResult.verified.cs | 4 + ...TeamMemberInviteEndpointResult.verified.cs | 10 +- .../PatchTeamMemberEndpoint.verified.cs | 4 +- .../PatchTeamMemberEndpointResult.verified.cs | 20 +- .../PostTeamMemberEndpoint.verified.cs | 1 + .../PostTeamMemberEndpointResult.verified.cs | 8 + ...ResendTeamMemberInviteEndpoint.verified.cs | 4 +- ...TeamMemberInviteEndpointResult.verified.cs | 20 +- .../Teams/DeleteTeamEndpoint.verified.cs | 1 + .../DeleteTeamEndpointResult.verified.cs | 8 + .../Teams/FreezeTeamEndpoint.verified.cs | 50 + .../FreezeTeamEndpointResult.verified.cs | 61 + .../Teams/GetTeamEndpoint.verified.cs | 2 + .../Teams/GetTeamEndpointResult.verified.cs | 16 + .../Teams/GetTeamsEndpoint.verified.cs | 4 +- .../Teams/GetTeamsEndpointResult.verified.cs | 16 + .../IDeleteTeamEndpointResult.verified.cs | 4 + .../IFreezeTeamEndpoint.verified.cs | 27 + .../IFreezeTeamEndpointResult.verified.cs | 37 + .../IGetTeamEndpointResult.verified.cs | 8 + .../IGetTeamsEndpointResult.verified.cs | 8 + .../IPatchTeamEndpointResult.verified.cs | 4 + .../IPostTeamEndpointResult.verified.cs | 4 + .../IUnfreezeTeamEndpoint.verified.cs | 27 + .../IUnfreezeTeamEndpointResult.verified.cs | 37 + .../Teams/PatchTeamEndpoint.verified.cs | 1 + .../Teams/PatchTeamEndpointResult.verified.cs | 8 + .../Teams/PostTeamEndpoint.verified.cs | 1 + .../Teams/PostTeamEndpointResult.verified.cs | 8 + .../Teams/UnfreezeTeamEndpoint.verified.cs | 49 + .../UnfreezeTeamEndpointResult.verified.cs | 61 + .../Users/GetUserEndpoint.verified.cs | 49 + .../GetUserEndpointResult.verified.cs} | 22 +- .../Users/GetUsersEndpoint.verified.cs | 53 + .../Users/GetUsersEndpointResult.verified.cs | 61 + .../Interfaces/IGetUserEndpoint.verified.cs | 27 + .../IGetUserEndpointResult.verified.cs | 37 + .../Interfaces/IGetUsersEndpoint.verified.cs | 27 + .../IGetUsersEndpointResult.verified.cs | 37 + ...GetWalletTransactions1Endpoint.verified.cs | 50 + ...letTransactions1EndpointResult.verified.cs | 61 + .../GetWalletTransactionsEndpoint.verified.cs | 3 + ...lletTransactionsEndpointResult.verified.cs | 16 + ...etWalletTransactions1Endpoint.verified.cs} | 10 +- ...etTransactions1EndpointResult.verified.cs} | 12 +- ...lletTransactionsEndpointResult.verified.cs | 8 + ...tmentTransactionEndpointResult.verified.cs | 4 + ...rAdjustmentTransactionEndpoint.verified.cs | 1 + ...tmentTransactionEndpointResult.verified.cs | 8 + .../Wallets/GetWalletsEndpoint.verified.cs | 2 + .../GetWalletsEndpointResult.verified.cs | 16 + .../IGetWalletsEndpointResult.verified.cs | 8 + .../DeleteWebhookConfigEndpoint.verified.cs | 2 + ...eteWebhookConfigEndpointResult.verified.cs | 16 + .../GetWebhookConfigEndpoint.verified.cs | 1 + ...GetWebhookConfigEndpointResult.verified.cs | 8 + .../GetWebhookEntries1Endpoint.verified.cs | 1 + ...tWebhookEntries1EndpointResult.verified.cs | 8 + .../GetWebhookEntriesEndpoint.verified.cs | 2 + ...etWebhookEntriesEndpointResult.verified.cs | 16 + ...eteWebhookConfigEndpointResult.verified.cs | 8 + ...GetWebhookConfigEndpointResult.verified.cs | 4 + ...tWebhookEntries1EndpointResult.verified.cs | 4 + ...etWebhookEntriesEndpointResult.verified.cs | 8 + ...ateWebhookConfigEndpointResult.verified.cs | 8 + .../UpdateWebhookConfigEndpoint.verified.cs | 2 + ...ateWebhookConfigEndpointResult.verified.cs | 16 + .../GlobalUsings.verified.cs | 12 + 558 files changed, 21475 insertions(+), 4683 deletions(-) create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/ChargePointStatisticsDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/Performance.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/RequestParameters/GetChargePointStatisticsParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/RequestParameters/GetSiteStatisticsParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/States.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/TimePeriod.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/ChargePointOcppLog.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MontaPageChargePointOcppLogDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/GetChargePointOcppLogsParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/RebootChargePointParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/UnlockChargePointParameters.verified.cs rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/{Currencies/CurrencyDto4.verified.cs => Charges/Currency11.verified.cs} (59%) create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency5.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency9.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PatchGenericPaymentSession.verified.cs rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/{_Shared/PublicUser.verified.cs => Charges/PublicUser3.verified.cs} (88%) create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightByChargeAuthTokenReportDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightByChargeAuthTokenReportDtoConsumption.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReport.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReportDtoConsumption.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReportDtoConsumptionCountryBreakdown.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/MontaPageChargesInsightByChargeAuthTokenReportDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/MontaPageChargesInsightDriverMemberCostsReportDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesChargeAuthTokenReportParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesDriverMemberCostsReportParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/InvoiceDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/MontaPageInvoiceDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/RequestParameters/GetInvoice1Parameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/RequestParameters/GetInvoiceParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/MontaPageNestedTeamDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/NestedTeam.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/NestedTeamInvite.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PatchNestedTeam.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PriceGroup1.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PublicTeam.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PublicUser.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/AcceptInviteParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/DeleteNestedTeamParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/GetNestedTeamParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/GetNestedTeamsParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/InviteParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/RejectInviteParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/UpdateNestedTeamParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/Currency1.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Prices/Currency17.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/MontaPageReportDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/ReasonDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/ReportDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/RequestParameters/GetReportParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/RequestParameters/GetReportsParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/PublicUser1.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SubscriptionPurchases/Currency3.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/TariffPeriodGroup1.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/TariffPeriodGroup2.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/CreateTeamMemberProfile.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/MontaPageTeamMemberProfileDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/PatchTeamMemberProfile.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/DeleteTeamMemberProfileParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/GetTeamMemberProfileParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/GetTeamMemberProfilesParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/PostTeamMemberProfileParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/UpdateTeamMemberProfileParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/TeamMemberProfile.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/RequestParameters/AcceptTeamMemberJoinRequestParameters.verified.cs rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/{TeamMemberDto.verified.cs => TeamMember.verified.cs} (70%) create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/Currency7.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/FreezeTeamParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/UnfreezeTeamParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/TeamDtoTeamCategoryDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/UpdateTeamStateDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/MontaPageUserDto.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/RequestParameters/GetUserParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/RequestParameters/GetUsersParameters.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/User.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/Currency13.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/Currency14.verified.cs rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/{PatchTransactionParameters.verified.cs => GetWalletTransactions1Parameters.verified.cs} (65%) create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberAccess1.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState1.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState3.verified.cs rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/{Currencies/CurrencyDto3.verified.cs => _Shared/CurrencyDto.verified.cs} (87%) create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Pageable.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/SimCard.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetChargePointStatisticsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetChargePointStatisticsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetSiteStatisticsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetSiteStatisticsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetChargePointStatisticsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetChargePointStatisticsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetSiteStatisticsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetSiteStatisticsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointOcppLogsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointOcppLogsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointOcppLogsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointOcppLogsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IRebootChargePointEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IRebootChargePointEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IUnlockChargePointEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IUnlockChargePointEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/RebootChargePointEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/RebootChargePointEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/UnlockChargePointEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/UnlockChargePointEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargeAuthTokenReportEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargeAuthTokenReportEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverMemberCostsReportEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverMemberCostsReportEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargeAuthTokenReportEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargeAuthTokenReportEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverMemberCostsReportEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverMemberCostsReportEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoice1Endpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoice1EndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoiceEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoiceEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoice1Endpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoice1EndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoiceEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoiceEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/AcceptInviteEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/AcceptInviteEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/DeleteNestedTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/DeleteNestedTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IAcceptInviteEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IAcceptInviteEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IDeleteNestedTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IDeleteNestedTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IInviteEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IInviteEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IRejectInviteEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IRejectInviteEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IUpdateNestedTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IUpdateNestedTeamEndpointResult.verified.cs rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/{WalletTransactions/PatchTransactionEndpoint.verified.cs => NestedTeams/InviteEndpoint.verified.cs} (70%) create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/InviteEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/RejectInviteEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/RejectInviteEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/UpdateNestedTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/UpdateNestedTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportsEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportsEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/DeleteTeamMemberProfileEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/DeleteTeamMemberProfileEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfileEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfileEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfilesEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfilesEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IDeleteTeamMemberProfileEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IDeleteTeamMemberProfileEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfileEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfileEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfilesEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfilesEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IPostTeamMemberProfileEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IPostTeamMemberProfileEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IUpdateTeamMemberProfileEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IUpdateTeamMemberProfileEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/PostTeamMemberProfileEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/PostTeamMemberProfileEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/UpdateTeamMemberProfileEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/UpdateTeamMemberProfileEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/AcceptTeamMemberJoinRequestEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/AcceptTeamMemberJoinRequestEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IAcceptTeamMemberJoinRequestEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IAcceptTeamMemberJoinRequestEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/FreezeTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/FreezeTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IFreezeTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IFreezeTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IUnfreezeTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IUnfreezeTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/UnfreezeTeamEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/UnfreezeTeamEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUserEndpoint.verified.cs rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/{WalletTransactions/PatchTransactionEndpointResult.verified.cs => Users/GetUserEndpointResult.verified.cs} (72%) create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUsersEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUsersEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUserEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUserEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUsersEndpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUsersEndpointResult.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactions1Endpoint.verified.cs create mode 100644 test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactions1EndpointResult.verified.cs rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/{IPatchTransactionEndpoint.verified.cs => IGetWalletTransactions1Endpoint.verified.cs} (76%) rename test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/{IPatchTransactionEndpointResult.verified.cs => IGetWalletTransactions1EndpointResult.verified.cs} (71%) diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/Monta.yaml b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/Monta.yaml index 2169418b2..d427426b7 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/Monta.yaml +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/Monta.yaml @@ -1,7 +1,8 @@ openapi: 3.0.1 info: title: MONTA Partner API - description: "\n see https://docs.partner-api.monta.com\n " + description: "\n see https://docs.partner-api.monta.com\n \ + \ " contact: name: Partner API Support url: https://www.monta.com/uk/contact @@ -10,6 +11,7 @@ info: servers: - url: https://partner-api.monta.com description: Production +security: [] paths: /api/v1/auth/me: get: @@ -25,7 +27,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/Consumer' + $ref: "#/components/schemas/Consumer" "401": description: Unauthorized access content: @@ -73,7 +75,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/Token' + $ref: "#/components/schemas/Token" "401": description: Unauthorized access content: @@ -120,7 +122,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/Token' + $ref: "#/components/schemas/Token" "401": description: Consumer with provided credentials was not found content: @@ -168,7 +170,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -176,24 +178,46 @@ paths: type: integer format: int32 default: 10 - example: "10" + example: 10 responses: "200": description: List of charge auth tokens that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargeAuthTokenDto_' + $ref: "#/components/schemas/MontaPage_ChargeAuthTokenDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -216,7 +240,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/CreateChargeAuthToken' + $ref: "#/components/schemas/CreateChargeAuthToken" required: true responses: "201": @@ -224,7 +248,29 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargeAuthToken' + $ref: "#/components/schemas/ChargeAuthToken" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -245,16 +291,6 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] /api/v1/charge-auth-tokens/{chargeAuthTokenId}: @@ -277,17 +313,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargeAuthToken' - "403": - description: Operator doesn't have access to resource - content: - application/json: - schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/ChargeAuthToken" "404": description: Entity with the provided id was not found content: @@ -300,26 +326,36 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] delete: @@ -338,16 +374,6 @@ paths: responses: "200": description: Deleted charge auth token successfully - "403": - description: Operator doesn't have access to resource - content: - application/json: - schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN "404": description: Entity with the provided id was not found content: @@ -360,26 +386,36 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] patch: @@ -399,7 +435,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/PatchChargeAuthToken' + $ref: "#/components/schemas/PatchChargeAuthToken" required: true responses: "200": @@ -407,7 +443,29 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargeAuthToken' + $ref: "#/components/schemas/ChargeAuthToken" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -428,16 +486,6 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] /api/v1/charge-auth-tokens/{chargeAuthTokenId}/block: @@ -460,7 +508,29 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargeAuthToken' + $ref: "#/components/schemas/ChargeAuthToken" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -481,16 +551,6 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] /api/v1/charge-auth-tokens/{chargeAuthTokenId}/unblock: @@ -513,7 +573,29 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargeAuthToken' + $ref: "#/components/schemas/ChargeAuthToken" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -534,16 +616,6 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] /api/v1/charge-point-brands: @@ -565,7 +637,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -573,35 +645,57 @@ paths: type: integer format: int32 default: 10 - example: "10" + example: 10 responses: "200": description: List of charge point brands that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargePointBrandDto_' - "401": - description: Unauthorized access + $ref: "#/components/schemas/MontaPage_ChargePointBrandDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - "400": - description: The request is invalid + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - security: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: - BearerAccessToken: [] /api/v1/charge-point-brands/{chargePointBrandId}: get: @@ -622,17 +716,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargePointBrand' - "403": - description: Operator doesn't have access to resource - content: - application/json: - schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/ChargePointBrand" "404": description: Entity with the provided id was not found content: @@ -645,26 +729,36 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] /api/v1/charge-point-connectors: @@ -679,27 +773,49 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargePointConnectorDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_ChargePointConnectorDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] /api/v1/charge-point-connectors/{connectorId}: @@ -721,17 +837,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargePointConnector' - "403": - description: Operator doesn't have access to resource - content: - application/json: - schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/ChargePointConnector" "404": description: Entity with the provided id was not found content: @@ -744,26 +850,36 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] /api/v1/charge-point-integrations: @@ -781,7 +897,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -789,7 +905,7 @@ paths: type: integer format: int32 default: 10 - example: "10" + example: 10 - name: chargePointId in: query required: true @@ -818,27 +934,49 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargePointIntegrationDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_ChargePointIntegrationDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] put: @@ -853,7 +991,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/CreateOrUpdateChargePointIntegration' + $ref: "#/components/schemas/CreateOrUpdateChargePointIntegration" required: true responses: "200": @@ -861,7 +999,29 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargePointIntegration' + $ref: "#/components/schemas/ChargePointIntegration" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -882,16 +1042,6 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] /api/v1/charge-point-integrations/{chargePointIntegrationId}: @@ -914,17 +1064,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargePointIntegration' - "403": - description: Operator doesn't have access to resource - content: - application/json: - schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/ChargePointIntegration" "404": description: Entity with the provided id was not found content: @@ -937,26 +1077,36 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] delete: @@ -975,18 +1125,8 @@ paths: responses: "204": description: Charge point integration deleted - "403": - description: Operator doesn't have access to resource - content: - application/json: - schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN - "404": - description: Entity with the provided id was not found + "404": + description: Entity with the provided id was not found content: application/json: schema: @@ -997,26 +1137,36 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] /api/v1/charge-point-models: @@ -1044,7 +1194,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -1052,24 +1202,46 @@ paths: type: integer format: int32 default: 10 - example: "10" + example: 10 responses: "200": description: List of charge point models that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargePointModelDto_' + $ref: "#/components/schemas/MontaPage_ChargePointModelDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -1101,7 +1273,29 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargePointModel' + $ref: "#/components/schemas/ChargePointModel" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -1112,6 +1306,67 @@ paths: status: FORBIDDEN message: Operator doesn't have access to resource errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/charge-point-statistics/by-charge-point: + get: + tags: + - Charge Point Statistics + summary: Retrieve statistics related to a charge point + description: "Required scope: `charge-points:read`" + operationId: get-charge-point-statistics + parameters: + - name: chargePointId + in: query + required: true + schema: + minimum: 0 + exclusiveMinimum: true + required: + - "true" + type: integer + description: Filter to retrieve statistics for a given charge point by `chargePointId` + format: int64 + example: 123 + - name: fromDate + in: query + required: true + schema: + pattern: "\\d{4}-\\d{2}-\\d{2}" + type: string + description: "Filter to retrieve charge point statistics created from date\ + \ (YYYY-MM-DD), we expect a date in UTC
The maximum gap between from\ + \ and to data cannot be longer than 365 days" + format: date + example: 2022-05-01 + - name: toDate + in: query + required: true + schema: + pattern: "\\d{4}-\\d{2}-\\d{2}" + type: string + description: "Filter to retrieve charge point statistics created to date\ + \ (YYYY-MM-DD), we expect a date in UTC
The maximum gap between from\ + \ and to data cannot be longer than 365 days" + format: date + example: 2022-05-30 + responses: + "200": + description: Statistics that match the provided criteria + content: + application/json: + schema: + $ref: "#/components/schemas/ChargePointStatisticsDto" "404": description: Entity with the provided id was not found content: @@ -1124,6 +1379,26 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -1134,24 +1409,108 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/charge-point-statistics/by-site: + get: + tags: + - Charge Point Statistics + summary: Retrieve statistics related to a site + description: "Required scope: `charge-points:read`" + operationId: get-site-statistics + parameters: + - name: siteId + in: query + required: true + schema: + minimum: 0 + exclusiveMinimum: true + required: + - "true" + type: integer + description: Filter to retrieve statistics for a given site by `siteId` + format: int64 + example: 45 + - name: fromDate + in: query + required: true + schema: + pattern: "\\d{4}-\\d{2}-\\d{2}" + type: string + description: "Filter to retrieve charge point statistics created from date\ + \ (YYYY-MM-DD), we expect a date in UTC
The maximum gap between from\ + \ and to data cannot be longer than 365 days" + format: date + example: 2022-05-01 + - name: toDate + in: query + required: true + schema: + pattern: "\\d{4}-\\d{2}-\\d{2}" + type: string + description: "Filter to retrieve charge point statistics created to date\ + \ (YYYY-MM-DD), we expect a date in UTC
The maximum gap between from\ + \ and to data cannot be longer than 365 days" + format: date + example: 2022-05-30 + responses: + "200": + description: Statistics that match the provided criteria + content: + application/json: + schema: + $ref: "#/components/schemas/ChargePointStatisticsDto" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] /api/v1/charge-points: get: tags: - Charge Points - summary: Retrieve a list of charge points. - description: "Required scope: `charge-points:read`" + summary: Retrieve a list of charge points + description: "Required scope: `charge-points:read`
Organization authorization:\ + \ `supported`" operationId: get-charge-points parameters: - name: page @@ -1161,7 +1520,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -1169,7 +1528,7 @@ paths: type: integer format: int32 default: 10 - example: "10" + example: 10 - name: siteId in: query schema: @@ -1186,7 +1545,7 @@ paths: required: - "false" type: integer - description: Allows to filter list of charge points by a team id. + description: Allows to filter list of charge points by a team id format: int64 nullable: true example: 19 @@ -1212,6 +1571,26 @@ paths: \ -8.050000, -34.900002)" nullable: true example: "55.7096,12.5856" + - name: boundingBox + in: query + schema: + required: + - "false" + type: string + description: "Bounding box coordinates for filtering. The format should\ + \ be 'minLat,minLon,maxLat,maxLon'" + nullable: true + example: "55.0,12.0,56.0,13.0" + - name: operatorId + in: query + schema: + required: + - "false" + type: integer + description: Allows filtering charge point by `operatorId` + format: int64 + nullable: true + example: 1 - name: includeDeleted in: query schema: @@ -1219,56 +1598,90 @@ paths: - "false" type: boolean description: Includes deleted resources in the response - nullable: true example: false + default: false + - name: includePublic + in: query + schema: + required: + - "false" + type: boolean + description: "Includes public charge points from other operators in the\ + \ response**Note: Only supported from Version `2024-07-01`**" + example: false + default: false - name: state in: query schema: + description: Allows filtering charge points by their state nullable: true + example: busy allOf: - - $ref: '#/components/schemas/ChargePointState' - - description: Allows filtering charge points by their state - example: busy + - $ref: "#/components/schemas/ChargePointState" + - {} responses: "200": description: List of charges points that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargePointDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_ChargePointDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] post: tags: - Charge Points summary: Create a charge point - description: "Required scope: `charge-points:write`" + description: "Required scope: `charge-points:write`
Organization authorization:\ + \ `supported`" operationId: post-charge-point requestBody: content: application/json: schema: - $ref: '#/components/schemas/CreateChargePoint' + $ref: "#/components/schemas/CreateChargePoint" required: true responses: "201": @@ -1276,7 +1689,29 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargePoint' + $ref: "#/components/schemas/ChargePoint" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -1297,24 +1732,14 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] /api/v1/charge-points/map: get: tags: - Charge Points - summary: Retrieve charge points / sites for map. - description: "Required scope: `map:read`" + summary: Retrieve charge points / sites for map + description: "Required scope: `map:read`. **RateLimit-Policy: `Fair-Use`**" operationId: get-charge-point-map parameters: - name: topLatitude @@ -1434,35 +1859,58 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/MapResult' - "400": - description: The request is invalid + $ref: "#/components/schemas/MapResult" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] /api/v1/charge-points/{chargePointId}: get: tags: - Charge Points - summary: Retrieve a single charge point. - description: "Required scope: `charge-points:read`" + summary: Retrieve a single charge point + description: "Required scope: `charge-points:read`
Organization authorization:\ + \ `supported`" operationId: get-charge-point parameters: - name: chargePointId @@ -1477,17 +1925,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargePoint' - "403": - description: Operator doesn't have access to resource - content: - application/json: - schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/ChargePoint" "404": description: Entity with the provided id was not found content: @@ -1500,33 +1938,44 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] delete: tags: - Charge Points summary: Delete an existing charge point - description: "Required scope: `charge-points:delete`" + description: "Required scope: `charge-points:delete`
Organization authorization:\ + \ `supported`" operationId: delete-charge-point parameters: - name: chargePointId @@ -1538,6 +1987,28 @@ paths: responses: "204": description: Charge point deleted + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -1558,23 +2029,14 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] patch: tags: - Charge Points summary: Patch an existing charge point - description: "Required scope: `charge-points:write`" + description: "Required scope: `charge-points:write`
Organization authorization:\ + \ `supported`" operationId: patch-charge-point parameters: - name: chargePointId @@ -1587,7 +2049,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/PatchChargePoint' + $ref: "#/components/schemas/PatchChargePoint" required: true responses: "200": @@ -1595,7 +2057,29 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ChargePoint' + $ref: "#/components/schemas/ChargePoint" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -1616,25 +2100,15 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/charges: + /api/v1/charge-points/{chargePointId}/logs: get: tags: - - Charges - summary: Retrieve a list of charges. - description: "Required scope: `charge-transactions:read`" - operationId: get-charges + - Charge Points + summary: Retrieve charge point OCPP logs + description: "Required scope: `charge-points:read`" + operationId: get-charge-point-ocpp-logs parameters: - name: page in: query @@ -1643,7 +2117,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -1651,119 +2125,75 @@ paths: type: integer format: int32 default: 10 - example: "10" - - name: teamId - in: query - schema: - type: integer - description: Filter to retrieve charges with specified `teamId` - format: int64 - nullable: true - example: 13 + example: 10 - name: chargePointId - in: query + in: path + required: true schema: type: integer - description: Filter to retrieve charges with specified `chargePointId` format: int64 - nullable: true - example: 10 - - name: siteId + - name: fromDate in: query schema: - type: integer - description: Filter to retrieve charges with specified `siteId` - format: int64 + required: + - "false" + type: string + description: "Filter to retrieve charge point logs created from date, a\ + \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')" + format: date-time nullable: true - example: 5 - - name: state + example: 2024-05-22T09:30:03Z + - name: toDate in: query schema: + required: + - "false" type: string - description: Filter to retrieve charges by `state` + description: "Filter to retrieve charge point logs to date, a date in UTC\ + \ and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')" + format: date-time nullable: true - example: charging - enum: - - reserved - - starting - - charging - - stopping - - paused - - scheduled - - stopped - - completed - - name: fromDate - in: query - schema: - type: string - description: "Filter to retrieve charges where `createdAt` >= `fromDate`\ - \ (ISO8601: yyyy-MM-ddTHH:mm:ssZ)" - format: date-time - nullable: true - example: 2022-05-22T09:30:03Z - - name: toDate - in: query - schema: - type: string - description: "Filter to retrieve charges where `createdAt` <= `toDate` (ISO8601:\ - \ yyyy-MM-ddTHH:mm:ssZ)" - format: date-time - nullable: true - example: 2022-05-22T09:30:03Z - - name: chargeAuthType - in: query - schema: - nullable: true - allOf: - - $ref: '#/components/schemas/ChargeAuthenticationType' - - description: "Filter to retrieve charges by the charge authentication\ - \ type, must be combined with `chargeAuthId`" - example: vehicleId - - name: chargeAuthId - in: query - schema: - type: string - description: "Filter to retrieve charges by the charge authentication id,\ - \ must be combined with `chargeAuthType`
*Note*: for type vehicleId\ - \ `chargeAuthId` must not include the VID: prefix" - nullable: true - example: 38C58DB85XXX - - name: partnerExternalId - in: query - schema: - type: string - description: "Filter charges by `partnerExternalId`, to filter only resources\ - \ without `partnerExternalId` *use* `partnerExternalId=\"\"`" - nullable: true - example: "10001" - - name: operatorRole - in: query - schema: - nullable: true - allOf: - - $ref: '#/components/schemas/OperatorRole' - - description: Filter to indicate the desired role to list charges
e.g - owner will always deliver charges from the operator charge points
payer - will deliver charges paid by the operator - example: owner - default: owner + example: 2024-05-23T09:30:03Z responses: "200": - description: List of charges that match the criteria + description: "Charge point OCPP logs with provided id. Note: Response from\ + \ this endpoint is not considered type-safe and might change over time" + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_ChargePointOcppLogDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargeDto_' + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -1776,25 +2206,24 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] + /api/v1/charge-points/{chargePointId}/reboot: post: tags: - - Charges - summary: Start a charge. - description: "Required scope: `control-charging:write`" - operationId: start-charge - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/StartChargeRequest' + - Charge Points + summary: Reboot an existing charge point + description: "Required scope: `charge-points:write`
Organization authorization:\ + \ `supported`" + operationId: reboot-charge-point + parameters: + - name: chargePointId + in: path required: true + schema: + type: integer + format: int64 responses: - "200": - description: Charge successfully started - content: - application/json: - schema: - $ref: '#/components/schemas/Charge' + "204": + description: Charge point rebooted "404": description: Entity with the provided id was not found content: @@ -1807,109 +2236,26 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/charges/insights: - get: - tags: - - Charges Insights - summary: Retrieve insights about charges. - description: |- - Required scope: `charge-transactions:read`. - **Deprecated, use `/insights/charges/driver-report` and `/insights/charges/charger-report` instead.** - operationId: get-charges-insights - parameters: - - name: fromDate - in: query - required: true - schema: - pattern: "^(\\d{4}-\\d{2}-\\d{2})$" - type: string - description: "Filter to retrieve charge insights created from date (YYYY-MM-DD),\ - \ we expect a date in UTC
The maximum gap between from and to data\ - \ cannot be longer than 31 days" - format: date - example: 2022-05-01 - - name: toDate - in: query - required: true - schema: - pattern: "^(\\d{4}-\\d{2}-\\d{2})$" - type: string - description: "Filter to retrieve charge insights created to date (YYYY-MM-DD),\ - \ we expect a date in UTC
The maximum gap between from and to data\ - \ cannot be longer than 31 days" - format: date - example: 2022-05-30 - - name: teamId - in: query - schema: - type: integer - description: Filter to retrieve charges insights by the specified `teamId` - format: int64 - nullable: true - example: 13 - - name: chargePointId - in: query - schema: - type: integer - description: Filter to retrieve charges insights by the specified `chargePointId` - format: int64 - nullable: true - example: 13 - - name: siteId - in: query - schema: - type: integer - description: Filter to retrieve charges insights by the specified `siteId` - format: int64 - nullable: true - example: 13 - - name: teamMemberId - in: query - schema: - type: integer - description: Filter to retrieve charges insights by the specified `teamMemberId` - format: int64 - nullable: true - example: 13 - responses: - "200": - description: Charge insights for the given filter - content: - application/json: - schema: - $ref: '#/components/schemas/ChargesInsight' - "401": - description: Unauthorized access + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -1920,53 +2266,58 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - deprecated: true security: - BearerAccessToken: [] - x-sunset: 2024-04-01 - /api/v1/charges/{chargeId}: - get: + /api/v1/charge-points/{chargePointId}/unlock: + post: tags: - - Charges - summary: Retrieve a single charge. - description: "Required scope: `charge-transactions:read`" - operationId: get-charge + - Charge Points + summary: Unlock an existing charge point + description: "Required scope: `charge-points:write`
Organization authorization:\ + \ `supported`" + operationId: unlock-charge-point parameters: - - name: chargeId + - name: chargePointId in: path required: true schema: type: integer format: int64 responses: - "200": - description: Charge with provided id + "204": + description: Charge point unlocked + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/Charge' - "403": - description: Operator doesn't have access to resource + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN - "404": - description: Entity with the provided id was not found + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: NOT_FOUND - message: Requested entity/entity provided in body was not found - readableMessage: user friendly message - errorCode: RESOURCE_NOT_FOUND - context: context + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -1977,99 +2328,170 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - patch: + /api/v1/charges: + get: tags: - Charges - summary: Patch an existing charge - description: "Required scope: `charges:write`" - operationId: patch-charge + summary: Retrieve a list of charges + description: "Required scope: `charge-transactions:read`
Organization authorization:\ + \ `supported`" + operationId: get-charges parameters: - - name: chargeId - in: path - required: true - schema: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: teamId + in: query + schema: type: integer + description: Filter to retrieve charges with specified `teamId` format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/PatchCharge' - required: true + nullable: true + example: 13 + - name: operatorId + in: query + schema: + type: integer + description: "Filter to retrieve charges with specified `operatorId`
*Note*:\ + \ When not provided and `operatorRole = payer` the default operator will\ + \ be used for the given consumer, if the default operator cannot be assigned\ + \ the request will be rejected" + format: int64 + nullable: true + example: 96 + - name: chargePointId + in: query + schema: + type: integer + description: Filter to retrieve charges with specified `chargePointId` + format: int64 + nullable: true + example: 10 + - name: siteId + in: query + schema: + type: integer + description: Filter to retrieve charges with specified `siteId` + format: int64 + nullable: true + example: 5 + - name: state + in: query + schema: + type: string + description: Filter to retrieve charges by `state` + nullable: true + example: charging + enum: + - reserved + - starting + - charging + - stopping + - paused + - scheduled + - stopped + - completed + - name: fromDate + in: query + schema: + type: string + description: "Filter to retrieve charges where `createdAt` >= `fromDate`\ + \ (ISO8601: yyyy-MM-ddTHH:mm:ssZ)" + format: date-time + nullable: true + example: 2022-05-22T09:30:03Z + - name: toDate + in: query + schema: + type: string + description: "Filter to retrieve charges where `createdAt` <= `toDate` (ISO8601:\ + \ yyyy-MM-ddTHH:mm:ssZ)" + format: date-time + nullable: true + example: 2022-05-22T09:30:03Z + - name: chargeAuthType + in: query + schema: + description: "Filter to retrieve charges by the charge authentication type,\ + \ must be combined with `chargeAuthId`" + nullable: true + example: vehicleId + allOf: + - $ref: "#/components/schemas/ChargeAuthenticationType" + - {} + - name: chargeAuthId + in: query + schema: + type: string + description: "Filter to retrieve charges by the charge authentication id,\ + \ must be combined with `chargeAuthType`
*Note*: for type vehicleId\ + \ `chargeAuthId` must not include the VID: prefix" + nullable: true + example: 38C58DB85XXX + - name: partnerExternalId + in: query + schema: + type: string + description: "Filter charges by `partnerExternalId`, to filter only resources\ + \ without `partnerExternalId` *use* `partnerExternalId=\"\"`" + nullable: true + example: "10001" + - name: operatorRole + in: query + schema: + description: Filter to indicate the desired role to list charges
e.g + owner will always deliver charges from the operator charge points
payer + will deliver charges paid by the operator + nullable: true + example: owner + allOf: + - $ref: "#/components/schemas/OperatorRole" + - {} + default: owner responses: "200": - description: Charge updated - content: - application/json: - schema: - $ref: '#/components/schemas/Charge' - "403": - description: Operator doesn't have access to resource + description: List of charges that match the criteria content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_ChargeDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/charges/{chargeId}/breakdown: - get: - tags: - - Charges - summary: Retrieve a charge price and cost breakdown - description: "Required scope: `charges:read`*Note*: Please be aware that this\ - \ endpoint is currently in the BETA phase,calculations may return slightly\ - \ varying results, and the payload can change." - operationId: get-charge-breakdown - parameters: - - name: chargeId - in: path - required: true - schema: - type: integer - format: int64 - responses: - "200": - description: Charge Breakdown for the given id - content: - application/json: - schema: - $ref: '#/components/schemas/ChargeBreakdown' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -2090,39 +2512,28 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/charges/{chargeId}/restart: - get: + post: tags: - Charges - summary: Restart or start a reserved charge. - description: "Required scope: `control-charging:write`" - operationId: restart-charge - parameters: - - name: chargeId - in: path + summary: Start a charge + description: "Required scope: `control-charging:write`
Organization authorization:\ + \ `supported`" + operationId: start-charge + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/StartChargeRequest" required: true - schema: - type: integer - format: int64 responses: "200": - description: Successfully restarted charge/started reserved charge + description: Charge successfully started content: application/json: schema: - $ref: '#/components/schemas/Charge' + $ref: "#/components/schemas/Charge" "404": description: Entity with the provided id was not found content: @@ -2135,6 +2546,16 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -2155,43 +2576,83 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/charges/{chargeId}/stop: + /api/v1/charges/insights: get: tags: - - Charges - summary: Stop a charge. - description: "Required scope: `control-charging:write`" - operationId: stop-charge + - Charges Insights + summary: Retrieve insights about charges. + description: |- + Required scope: `charge-transactions:read`. + **Deprecated, use `/insights/charges/driver-report` and `/insights/charges/charger-report` instead.** + operationId: get-charges-insights parameters: - - name: chargeId - in: path + - name: fromDate + in: query required: true + schema: + pattern: "^(\\d{4}-\\d{2}-\\d{2})$" + type: string + description: "Filter to retrieve charge insights created from date (YYYY-MM-DD),\ + \ we expect a date in UTC
The maximum gap between from and to data\ + \ cannot be longer than 31 days" + format: date + example: 2022-05-01 + - name: toDate + in: query + required: true + schema: + pattern: "^(\\d{4}-\\d{2}-\\d{2})$" + type: string + description: "Filter to retrieve charge insights created to date (YYYY-MM-DD),\ + \ we expect a date in UTC
The maximum gap between from and to data\ + \ cannot be longer than 31 days" + format: date + example: 2022-05-30 + - name: teamId + in: query schema: type: integer + description: Filter to retrieve charges insights by the specified `teamId` format: int64 - responses: - "200": - description: Successfully stopped a charge - content: - application/json: - schema: - $ref: '#/components/schemas/Charge' - "404": - description: Entity with the provided id was not found - content: - application/json: + nullable: true + example: 13 + - name: chargePointId + in: query + schema: + type: integer + description: Filter to retrieve charges insights by the specified `chargePointId` + format: int64 + nullable: true + example: 13 + - name: siteId + in: query + schema: + type: integer + description: Filter to retrieve charges insights by the specified `siteId` + format: int64 + nullable: true + example: 13 + - name: teamMemberId + in: query + schema: + type: integer + description: Filter to retrieve charges insights by the specified `teamMemberId` + format: int64 + nullable: true + example: 13 + responses: + "200": + description: Charge insights for the given filter + content: + application/json: + schema: + $ref: "#/components/schemas/ChargesInsight" + "404": + description: Entity with the provided id was not found + content: + application/json: schema: type: object example: @@ -2200,6 +2661,16 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -2220,41 +2691,64 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + deprecated: true security: - BearerAccessToken: [] - /api/v1/consumers/me: + x-sunset: 2024-04-01 + /api/v1/charges/{chargeId}: get: tags: - - Consumer - summary: Obtain information about current API Consumer - operationId: get-current-consumer + - Charges + summary: Retrieve a single charge + description: "Required scope: `charge-transactions:read`
Organization authorization:\ + \ `supported`" + operationId: get-charge + parameters: + - name: chargeId + in: path + required: true + schema: + type: integer + format: int64 responses: "200": - description: Successfully retrieved current consumer + description: Charge with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/Charge" + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/Consumer' + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -2267,63 +2761,65 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/countries: - get: + patch: tags: - - Countries - summary: 'Retrieve a countries. ' - description: "Note: no pagination support" - operationId: getCountries - parameters: [] + - Charges + summary: Patch an existing charge + description: "Required scope: `charges:write`
Organization authorization:\ + \ `supported`" + operationId: patch-charge + parameters: + - name: chargeId + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PatchCharge" + required: true responses: "200": - description: List of countries + description: Charge updated content: application/json: schema: - $ref: '#/components/schemas/MontaPage_CountryDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/Charge" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/countries/{id}: - get: - tags: - - Countries - summary: Retrieve a country. - operationId: getCountry - parameters: - - name: id - in: path - required: true - schema: - type: integer - format: int64 - responses: - "200": - description: Country with provided id + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/Country' + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -2334,87 +2830,85 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/country-areas: + /api/v1/charges/{chargeId}/breakdown: get: tags: - - Country Areas - summary: Retrieve a country areas. - description: "Note: no pagination support" - operationId: getCountriesAreas + - Charges + summary: Retrieve a charge price and cost breakdown + description: "Required scope: `charges:read`*Note*: Please be aware that this\ + \ endpoint is currently in the BETA phase,calculations may return slightly\ + \ varying results, and the payload can change." + operationId: get-charge-breakdown parameters: - - name: countryId - in: query + - name: chargeId + in: path required: true schema: - minimum: 0 - exclusiveMinimum: true - required: - - "true" type: integer - description: Allows to filter country areas by country Id format: int64 - example: 13 responses: "200": - description: List of country areas + description: Charge Breakdown for the given id content: application/json: schema: - $ref: '#/components/schemas/MontaPage_CountryAreaDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/ChargeBreakdown" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - "404": - description: Entity with the provided id was not found + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: NOT_FOUND - message: Requested entity/entity provided in body was not found - readableMessage: user friendly message - errorCode: RESOURCE_NOT_FOUND - context: context + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/country-areas/{id}: + /api/v1/charges/{chargeId}/restart: get: tags: - - Country Areas - summary: Retrieve a country area. - operationId: getCountryArea + - Charges + summary: Restart or start a reserved charge + description: "Required scope: `control-charging:write`
Organization authorization:\ + \ `supported`" + operationId: restart-charge parameters: - - name: id + - name: chargeId in: path required: true schema: @@ -2422,84 +2916,43 @@ paths: format: int64 responses: "200": - description: Country area with provided id + description: Successfully restarted charge/started reserved charge content: application/json: schema: - $ref: '#/components/schemas/CountryArea' - "400": - description: The request is invalid + $ref: "#/components/schemas/Charge" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - "404": - description: Entity with the provided id was not found + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: NOT_FOUND - message: Requested entity/entity provided in body was not found - readableMessage: user friendly message - errorCode: RESOURCE_NOT_FOUND - context: context - security: - - BearerAccessToken: [] - /api/v1/currencies: - get: - tags: - - Currencies - summary: Retrieve a list of currencies - operationId: get-currencies - parameters: - - name: page - in: query - description: page number to retrieve (starts with 0) - schema: - type: integer - format: int32 - default: 0 - example: "1" - - name: perPage - in: query - description: "number of items per page (between 1 and 100, default 10)" - schema: - type: integer - format: int32 - default: 10 - example: "10" - - name: identifier - in: query - schema: - required: - - "false" - type: string - description: Allows to filter by ISO Alpha-3 currency code - nullable: true - example: eur - responses: - "200": - description: List of currencies that match the criteria - content: - application/json: - schema: - $ref: '#/components/schemas/MontaPage_CurrencyDto_' + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -2510,26 +2963,18 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/currencies/{currencyId}: + /api/v1/charges/{chargeId}/stop: get: tags: - - Currencies - summary: Retrieve a single currency - operationId: get-currency + - Charges + summary: Stop a charge + description: "Required scope: `control-charging:write`
Organization authorization:\ + \ `supported`" + operationId: stop-charge parameters: - - name: currencyId + - name: chargeId in: path required: true schema: @@ -2537,11 +2982,33 @@ paths: format: int64 responses: "200": - description: Currency with provided id + description: Successfully stopped a charge + content: + application/json: + schema: + $ref: "#/components/schemas/Charge" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found content: application/json: schema: - $ref: '#/components/schemas/CurrencyDto_4' + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -2552,6 +3019,31 @@ paths: status: FORBIDDEN message: Operator doesn't have access to resource errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/consumers/me: + get: + tags: + - Consumer + summary: Obtain information about current API Consumer + operationId: get-current-consumer + responses: + "200": + description: Successfully retrieved current consumer + content: + application/json: + schema: + $ref: "#/components/schemas/Consumer" "404": description: Entity with the provided id was not found content: @@ -2564,94 +3056,85 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/insights/charges/charger-report: + /api/v1/countries: get: tags: - - Insights - summary: Retrieve insights about charge points. - description: |- - Required scope: `insights:read` - - Returns a list of charge points (owned by that `teamId`) with the number of charging sessions and the total Kwh consumed. - operationId: get-insights-charges-charger-report - parameters: - - name: teamId - in: query - required: true - schema: - required: - - "true" - type: integer - description: Filter to retrieve charge point insights by the specified `teamId` - format: int64 - example: 13 - - name: chargePointIds - in: query - schema: - required: - - "false" - type: string - description: Filter to retrieve charges insights by the specified (comma-separated) - list of `chargePointId` - nullable: true - example: "13,14,15" - - name: fromDate - in: query - required: true - schema: - type: string - description: "Filter to retrieve charge insights created from date, we expecta\ - \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum gap\ - \ between from and to data cannot be longer than 31 days" - format: date - - name: toDate - in: query - required: true - schema: - type: string - description: "Filter to retrieve charge insights created to date, we expecta\ - \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum gap\ - \ between from and to data cannot be longer than 31 days" - format: date + - Countries + summary: 'Retrieve a countries. ' + description: "Note: no pagination support" + operationId: getCountries + parameters: [] responses: "200": - description: Charger report for the given filter + description: List of countries + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_CountryDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargesInsightChargerReportDto_' + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -2664,90 +3147,58 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/insights/charges/driver-report: + /api/v1/countries/{id}: get: tags: - - Insights - summary: Retrieve insights about charges broken down by team members of a team. - description: |- - Required scope: `insights:read` - - Returns charge insights for the given teamId (and optionally `teamMemberIds`) broken down by team member. - Takes only charges into consideration that were paid for by the provided `teamId`. - - Note: Any values related to money are in the teams' currency. You can fetch them from `GET /api/v1/teams/{teamId}` - operationId: get-insights-charges-driver-report + - Countries + summary: Retrieve a country. + operationId: getCountry parameters: - - name: teamId - in: query + - name: id + in: path required: true schema: - required: - - "true" type: integer - description: Filter to retrieve charges insights by the specified `teamId` format: int64 - example: 13 - - name: teamMemberIds - in: query - schema: - required: - - "false" - type: string - description: Filter to retrieve charges insights by the specified (comma-separated) - list of `teamMemberId` - nullable: true - example: "13,14,15" - - name: fromDate - in: query - required: true - schema: - type: string - description: "Filter to retrieve charge insights created from date, we expecta\ - \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum gap\ - \ between from and to data cannot be longer than 31 days" - format: date - - name: toDate - in: query - required: true - schema: - type: string - description: "Filter to retrieve charge insights created to date, we expecta\ - \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum gap\ - \ between from and to data cannot be longer than 31 days" - format: date - - name: datesFilteredBy - in: query - schema: - nullable: true - allOf: - - $ref: '#/components/schemas/DriverReportDatesFilteredBy' - - type: string - description: "Use this to determine if the report should be filtered based\ - \ on completion dates of charges or wallet transactions.

Accepted\ - \ values:
- `charge-transaction`: Generates report based on charges'\ - \ `completedAt`. Default.- `wallet-transaction`: Generates report based\ - \ on wallet transactions' `completedAt`. Will not include any charges\ - \ without wallet transactions." - example: charge-transaction - default: charge-transaction responses: "200": - description: Driver report for the given filter + description: Country with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/Country" + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/MontaPage_ChargesInsightDriverReportDto_' + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -2760,108 +3211,55 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/installer-jobs: + /api/v1/country-areas: get: tags: - - Installer Jobs - summary: Retrieve a list of installer jobs - description: "Required scope: `installer-jobs:read`" - operationId: get-installer-jobs + - Country Areas + summary: Retrieve a country areas. + description: "Note: no pagination support" + operationId: getCountriesAreas parameters: - - name: page - in: query - description: page number to retrieve (starts with 0) - schema: - type: integer - format: int32 - default: 0 - example: "1" - - name: perPage - in: query - description: "number of items per page (between 1 and 100, default 10)" - schema: - type: integer - format: int32 - default: 10 - example: "10" - - name: siteId + - name: countryId in: query + required: true schema: + minimum: 0 + exclusiveMinimum: true required: - - "false" + - "true" type: integer - description: Allows to filter list of installer jobs by a site id + description: Allows to filter country areas by country Id format: int64 - nullable: true example: 13 - - name: teamId - in: query - schema: - required: - - "false" - type: integer - description: Allows to filter list of installer jobs by a team id. - format: int64 - nullable: true - example: 19 - - name: includeDeleted - in: query - schema: - required: - - "false" - type: boolean - description: "If true, deleted installer jobs will be included in the response." - nullable: true - example: true responses: "200": - description: List of installer jobs that match the criteria + description: List of country areas content: application/json: schema: - $ref: '#/components/schemas/MontaPage_InstallerJobDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_CountryAreaDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - post: - tags: - - Installer Jobs - summary: Create an installer job - description: "Create an installer job for a charge point site.
Required scope:\ - \ `installer-jobs:write`" - operationId: post-installer-job - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateInstallerJobDto' - required: true - responses: - "201": - description: Installer job created - content: - application/json: - schema: - $ref: '#/components/schemas/InstallerJob' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -2882,27 +3280,16 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/installer-jobs/{installerJobId}: + /api/v1/country-areas/{id}: get: tags: - - Installer Jobs - summary: Retrieve a single installer job - description: "Required scope: `installer-jobs:read`" - operationId: get-installer-job + - Country Areas + summary: Retrieve a country area. + operationId: getCountryArea parameters: - - name: installerJobId + - name: id in: path required: true schema: @@ -2910,21 +3297,11 @@ paths: format: int64 responses: "200": - description: Installer job with provided id - content: - application/json: - schema: - $ref: '#/components/schemas/InstallerJob' - "403": - description: Operator doesn't have access to resource + description: Country area with provided id content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/CountryArea" "404": description: Entity with the provided id was not found content: @@ -2937,44 +3314,16 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - delete: - tags: - - Installer Jobs - summary: Delete an existing installer job - description: "Required scope: `installer-jobs:delete`" - operationId: delete-installer-job - parameters: - - name: installerJobId - in: path - required: true - schema: - type: integer - format: int64 - responses: - "204": - description: Installer Job deleted + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -2995,79 +3344,99 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/operators: + /api/v1/currencies: get: tags: - - Operators - summary: Retrieve operators - description: "Required scope: `operators`" - operationId: get-operators - parameters: - - name: page + - Currencies + summary: Retrieve a list of currencies + operationId: get-currencies + parameters: + - name: page in: query + description: page number to retrieve (starts with 0) schema: type: integer - description: page number to retrieve (starts with 0) format: int32 - nullable: true - example: 1 default: 0 + example: 1 - name: perPage in: query + description: "number of items per page (between 1 and 100, default 10)" schema: type: integer format: int32 + default: 10 + example: 10 + - name: identifier + in: query + schema: + required: + - "false" + type: string + description: Allows to filter by ISO Alpha-3 currency code nullable: true + example: eur responses: "200": - description: List of operators that match the criteria + description: List of currencies that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_OperatorDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_CurrencyDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/operators/{id}: + /api/v1/currencies/{currencyId}: get: tags: - - Operators - summary: Retrieve an operator - description: "Required scope: `operators`" - operationId: get-operator + - Currencies + summary: Retrieve a single currency + operationId: get-currency parameters: - - name: id + - name: currencyId in: path required: true schema: @@ -3075,11 +3444,33 @@ paths: format: int64 responses: "200": - description: operator with provided id + description: Currency with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/CurrencyDto" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found content: application/json: schema: - $ref: '#/components/schemas/Operator' + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -3100,25 +3491,22 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/payment-terminals: + /api/v1/insights/charges/charge-auth-token-report: get: tags: - - Payment Terminals - summary: Retrieve a list of payment terminals - description: "Required scope: `payment-terminals:read`" - operationId: get-payment-terminals + - Insights + summary: Retrieve insights about charges broken down by charge auth token and + member cost groups of a team. + description: |- + Required scope: `insights:read` + + Returns charge insights for the given teamId (and optionally `chargeAuthTokenIds`) broken down by charge auth token and the member cost groups. + Takes only charges into consideration that were paid for by the provided `teamId`. + + Note: Any values related to money are in the teams' currency. You can fetch them from `GET /api/v1/teams/{teamId}` + operationId: get-insights-charges-charge-auth-token-report parameters: - name: page in: query @@ -3127,7 +3515,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -3135,52 +3523,59 @@ paths: type: integer format: int32 default: 10 - example: "10" - - name: serial - in: query - schema: - required: - - "false" - type: string - description: Allows to filter list of terminals by a serial - nullable: true - example: XYZ123-DF-123 + example: 10 - name: teamId in: query + required: true schema: + minimum: 0 + exclusiveMinimum: true required: - - "false" + - "true" type: integer - description: Allows to filter list of terminals by a team id. + description: Filter to retrieve charges insights by the specified `teamId` format: int64 - nullable: true - example: 19 - - name: includeDeleted + example: 13 + - name: fromDate in: query + required: true schema: - required: - - "false" - type: boolean - description: "If true, deleted entities will be included in the response." - nullable: true - example: true + type: string + description: "Filter to retrieve charge insights created from date, we expecta\ + \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum gap\ + \ between from and to data cannot be longer than 31 days" + format: date + - name: toDate + in: query + required: true + schema: + type: string + description: "Filter to retrieve charge insights created to date, we expecta\ + \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum gap\ + \ between from and to data cannot be longer than 31 days" + format: date + - name: datesFilteredBy + in: query + schema: + description: "Use this to determine if the report should be filtered based\ + \ on completion dates of charges or wallet transactions.

Accepted\ + \ values:
- `charge-transaction`: Generates report based on charges'\ + \ `completedAt`. Default.- `wallet-transaction`: Generates report based\ + \ on wallet transactions' `completedAt`. Will not include any charges\ + \ without wallet transactions." + nullable: true + example: charge-transaction + allOf: + - $ref: "#/components/schemas/DriverReportDatesFilteredBy" + - type: string + default: charge-transaction responses: "200": - description: List of payment terminals that match the criteria - content: - application/json: - schema: - $ref: '#/components/schemas/MontaPage_PaymentTerminalDto_' - "400": - description: The request is invalid + description: Charge Auth Token report for the given filter content: application/json: schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + $ref: "#/components/schemas/MontaPage_ChargesInsightByChargeAuthTokenReportDto_" "401": description: Unauthorized access content: @@ -3191,28 +3586,18 @@ paths: status: UNAUTHORIZED message: Invalid or expired `accessToken`. errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/payment-terminals/{paymentTerminalId}: - get: - tags: - - Payment Terminals - summary: Retrieve a single payment terminal - description: "Required scope: `payment-terminals:read`" - operationId: get-payment-terminal - parameters: - - name: paymentTerminalId - in: path - required: true - schema: - type: string - responses: - "200": - description: Payment Terminal with provided id + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/PaymentTerminal' + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "403": description: Operator doesn't have access to resource content: @@ -3223,18 +3608,6 @@ paths: status: FORBIDDEN message: Operator doesn't have access to resource errorCode: ACCESS_FORBIDDEN - "404": - description: Entity with the provided id was not found - content: - application/json: - schema: - type: object - example: - status: NOT_FOUND - message: Requested entity/entity provided in body was not found - readableMessage: user friendly message - errorCode: RESOURCE_NOT_FOUND - context: context "400": description: The request is invalid content: @@ -3245,25 +3618,18 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/plans: + /api/v1/insights/charges/charger-report: get: tags: - - Plans - summary: Retrieve plans - description: "Required scope: `plans:read`" - operationId: get-plans + - Insights + summary: Retrieve insights about charge points. + description: |- + Required scope: `insights:read` + + Returns a list of charge points (owned by that `teamId`) with the number of charging sessions and the total Kwh consumed. + operationId: get-insights-charges-charger-report parameters: - name: page in: query @@ -3272,7 +3638,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -3280,152 +3646,76 @@ paths: type: integer format: int32 default: 10 - example: "10" - responses: - "200": - description: List of plans that match the criteria - content: - application/json: - schema: - $ref: '#/components/schemas/MontaPage_PlanDto_' - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/plans/{id}: - get: - tags: - - Plans - summary: Retrieve a plan - description: "Required scope: `plans:read`" - operationId: get-plan - parameters: - - name: id - in: path + example: 10 + - name: teamId + in: query required: true schema: + minimum: 0 + exclusiveMinimum: true + required: + - "true" type: integer + description: Filter to retrieve charge point insights by the specified `teamId` format: int64 - responses: - "200": - description: Plan with provided id - content: - application/json: - schema: - $ref: '#/components/schemas/Plan' - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/price-group-tags: - get: - tags: - - Price Groups Tags - summary: Retrieve price group tags. - description: "Required scope: `price-groups:read`" - operationId: get-price-group-tags - parameters: - - name: name + example: 13 + - name: chargePointIds in: query schema: + required: + - "false" type: string - description: Filter to retrieve resources by the specified `name`. + description: Filter to retrieve charges insights by the specified (comma-separated) + list of `chargePointId` nullable: true - example: Energy - - name: partnerExternalId + example: "13,14,15" + - name: fromDate in: query + required: true schema: - required: - - "false" type: string - description: "Filter resources by partnerExternalId, to filter only resources\ - \ without `partnerExternalId` *use* `partnerExternalId=\"\"`" - nullable: true - example: 1A2B + description: "Filter to retrieve charge insights created from date, we expecta\ + \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum gap\ + \ between from and to data cannot be longer than 31 days" + format: date + - name: toDate + in: query + required: true + schema: + type: string + description: "Filter to retrieve charge insights created to date, we expecta\ + \ date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum gap\ + \ between from and to data cannot be longer than 31 days" + format: date responses: "200": - description: Price group tags for a given filter + description: Charger report for the given filter content: application/json: schema: - $ref: '#/components/schemas/MontaPage_PriceGroupTagDto_' - "401": - description: Unauthorized access + $ref: "#/components/schemas/MontaPage_ChargesInsightChargerReportDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - "400": - description: The request is invalid + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - security: - - BearerAccessToken: [] - post: - tags: - - Price Groups Tags - summary: Create a price group tag - description: "Required scope: `price-groups:write`" - operationId: post-price-group-tag - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreatePriceGroupTag' - required: true - responses: - "201": - description: Price group tag created - content: - application/json: - schema: - $ref: '#/components/schemas/PriceGroupTag' + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -3436,18 +3726,6 @@ paths: status: FORBIDDEN message: Operator doesn't have access to resource errorCode: ACCESS_FORBIDDEN - "404": - description: Entity with the provided id was not found - content: - application/json: - schema: - type: object - example: - status: NOT_FOUND - message: Requested entity/entity provided in body was not found - readableMessage: user friendly message - errorCode: RESOURCE_NOT_FOUND - context: context "400": description: The request is invalid content: @@ -3458,49 +3736,111 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/price-group-tags/{id}: + /api/v1/insights/charges/driver-member-costs-report: get: tags: - - Price Groups Tags - summary: Retrieve a single price group tag - description: "Required scope: `price-groups:read`" - operationId: get-price-group-tag + - Insights + summary: Retrieve insights about charges broken down by team members and member + cost groups of a team. + description: |- + Required scope: `insights:read` + + Returns charge insights for the given teamId (and optionally `teamMemberIds`) broken down by team member and the member cost groups. + Takes only charges into consideration that were paid for by the provided `teamId`. + + Note: Any values related to money are in the teams' currency. You can fetch them from `GET /api/v1/teams/{teamId}` + operationId: get-insights-charges-driver-member-costs-report parameters: - - name: id - in: path + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: teamId + in: query required: true schema: + minimum: 0 + exclusiveMinimum: true + required: + - "true" type: integer + description: Filter to retrieve charges insights by the specified `teamId` format: int64 + example: 13 + - name: teamMemberIds + in: query + schema: + required: + - "false" + type: string + description: Filter to retrieve charges insights by the specified (comma-separated) + list of `teamMemberId` + nullable: true + example: "13,14,15" + - name: fromDate + in: query + required: true + schema: + type: string + description: "Filter to retrieve charge insights created from date, we expect\ + \ a date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum\ + \ gap between from and to data cannot be longer than 31 days" + format: date + - name: toDate + in: query + required: true + schema: + type: string + description: "Filter to retrieve charge insights created to date, we expect\ + \ a date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum\ + \ gap between from and to data cannot be longer than 31 days" + format: date + - name: datesFilteredBy + in: query + schema: + description: "Use this to determine if the report should be filtered based\ + \ on completion dates of charges or wallet transactions.

Accepted\ + \ values:
- `charge-transaction`: Generates report based on charges'\ + \ `completedAt`. Default.- `wallet-transaction`: Generates report based\ + \ on wallet transactions' `completedAt`. Will not include any charges\ + \ without wallet transactions." + nullable: true + example: charge-transaction + allOf: + - $ref: "#/components/schemas/DriverReportDatesFilteredBy" + - type: string + default: charge-transaction responses: "200": - description: Price group tag with provided id + description: Driver report for the given filter content: application/json: schema: - $ref: '#/components/schemas/PriceGroupTag' - "403": - description: Operator doesn't have access to resource + $ref: "#/components/schemas/MontaPage_ChargesInsightDriverMemberCostsReportDto_" + "401": + description: Unauthorized access content: application/json: schema: type: object example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + status: UNAUTHORIZED + message: Invalid or expired `accessToken`. + errorCode: INVALID_ACCESS_TOKEN "404": description: Entity with the provided id was not found content: @@ -3513,54 +3853,120 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - delete: + /api/v1/insights/charges/driver-report: + get: tags: - - Price Groups Tags - summary: Delete an existing price group tag - description: "Required scope: `price-groups:delete`" - operationId: delete-price-group-tag + - Insights + summary: Retrieve insights about charges broken down by team members of a team. + description: |- + Required scope: `insights:read` + + Returns charge insights for the given teamId (and optionally `teamMemberIds`) broken down by team member. + Takes only charges into consideration that were paid for by the provided `teamId`. + + Note: Any values related to money are in the teams' currency. You can fetch them from `GET /api/v1/teams/{teamId}` + operationId: get-insights-charges-driver-report parameters: - - name: id - in: path + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: teamId + in: query required: true schema: + minimum: 0 + exclusiveMinimum: true + required: + - "true" type: integer + description: Filter to retrieve charges insights by the specified `teamId` format: int64 + example: 13 + - name: teamMemberIds + in: query + schema: + required: + - "false" + type: string + description: Filter to retrieve charges insights by the specified (comma-separated) + list of `teamMemberId` + nullable: true + example: "13,14,15" + - name: fromDate + in: query + required: true + schema: + type: string + description: "Filter to retrieve charge insights created from date, we expect\ + \ a date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum\ + \ gap between from and to data cannot be longer than 31 days" + format: date + - name: toDate + in: query + required: true + schema: + type: string + description: "Filter to retrieve charge insights created to date, we expect\ + \ a date in UTC and ISO8601 (YYYY-MM-DD'T'HH:MM:SS'Z')
The maximum\ + \ gap between from and to data cannot be longer than 31 days" + format: date + - name: datesFilteredBy + in: query + schema: + description: "Use this to determine if the report should be filtered based\ + \ on completion dates of charges or wallet transactions.

Accepted\ + \ values:
- `charge-transaction`: Generates report based on charges'\ + \ `completedAt`. Default.- `wallet-transaction`: Generates report based\ + \ on wallet transactions' `completedAt`. Will not include any charges\ + \ without wallet transactions." + nullable: true + example: charge-transaction + allOf: + - $ref: "#/components/schemas/DriverReportDatesFilteredBy" + - type: string + default: charge-transaction responses: "200": - description: Price group tag deleted - "403": - description: Operator doesn't have access to resource + description: Driver report for the given filter content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/MontaPage_ChargesInsightDriverReportDto_" "404": description: Entity with the provided id was not found content: @@ -3573,54 +3979,16 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - patch: - tags: - - Price Groups Tags - summary: Update a price group tag - description: "Required scope: `price-groups:write`" - operationId: patch-price-group-tag - parameters: - - name: id - in: path - required: true - schema: - type: integer - format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/PatchPriceGroupTag' - required: true - responses: - "200": - description: Price group tag updated - content: - application/json: - schema: - $ref: '#/components/schemas/PriceGroupTag' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -3631,18 +3999,6 @@ paths: status: FORBIDDEN message: Operator doesn't have access to resource errorCode: ACCESS_FORBIDDEN - "404": - description: Entity with the provided id was not found - content: - application/json: - schema: - type: object - example: - status: NOT_FOUND - message: Requested entity/entity provided in body was not found - readableMessage: user friendly message - errorCode: RESOURCE_NOT_FOUND - context: context "400": description: The request is invalid content: @@ -3653,126 +4009,164 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/price-groups: + /api/v1/installer-jobs: get: tags: - - Price Groups - summary: Retrieve a list of price groups. - description: "Required scope: `price-groups:read`" - operationId: getPriceGroups + - Installer Jobs + summary: Retrieve a list of installer jobs + description: "Required scope: `installer-jobs:read`" + operationId: get-installer-jobs parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: siteId + in: query + schema: + required: + - "false" + type: integer + description: Allows to filter list of installer jobs by a site id + format: int64 + nullable: true + example: 13 - name: teamId in: query - description: Filter to retrieve price groups with specified team id - required: true schema: + required: + - "false" type: integer + description: Allows to filter list of installer jobs by a team id. format: int64 + nullable: true + example: 19 + - name: includeDeleted + in: query + schema: + required: + - "false" + type: boolean + description: "If true, deleted installer jobs will be included in the response." + nullable: true + example: true responses: "200": - description: List of price groups that match the criteria + description: List of installer jobs that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_PriceGroupDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_InstallerJobDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] post: tags: - - Price Groups - summary: Creates a price group - description: "Required scope: `price-groups:write`" - operationId: create-price-group + - Installer Jobs + summary: Create an installer job + description: "Create an installer job for a charge point site.
Required scope:\ + \ `installer-jobs:write`" + operationId: post-installer-job requestBody: content: application/json: schema: - $ref: '#/components/schemas/CreateOrUpdatePriceGroupDto' + $ref: "#/components/schemas/CreateInstallerJobDto" required: true responses: - "404": - description: Team not found + "201": + description: Installer job created content: application/json: schema: - $ref: '#/components/schemas/MontaAppResponse' - "201": - description: Price group successfully created - "400": - description: The request is invalid + $ref: "#/components/schemas/InstallerJob" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/price-groups/{id}: - get: - tags: - - Price Groups - summary: Retrieve a price group. - description: "Required scope: `price-groups:read`" - operationId: getPriceGroup - parameters: - - name: id - in: path - required: true - schema: - type: integer - format: int64 - responses: - "200": - description: Price group with provided id + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/PriceGroup' + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -3783,94 +4177,61 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - put: + /api/v1/installer-jobs/{installerJobId}: + get: tags: - - Price Groups - summary: Updates a price group - description: "Required scope: `price-groups:write`" - operationId: update-price-group + - Installer Jobs + summary: Retrieve a single installer job + description: "Required scope: `installer-jobs:read`" + operationId: get-installer-job parameters: - - name: id + - name: installerJobId in: path required: true schema: type: integer format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateOrUpdatePriceGroupDto' - required: true responses: - "404": - description: Price group not found - content: - application/json: - schema: - $ref: '#/components/schemas/MontaAppResponse' "200": - description: Price group successfully updated + description: Installer job with provided id content: application/json: schema: - $ref: '#/components/schemas/PriceGroup' - "400": - description: The request is invalid + $ref: "#/components/schemas/InstallerJob" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - delete: - tags: - - Price Groups - summary: Deletes a price group - description: "Required scope: `price-groups:delete`" - operationId: delete-price-group - parameters: - - name: id - in: path - required: true - schema: - type: integer - format: int64 - responses: - "404": - description: Price group not found + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/MontaAppResponse' - "204": - description: Price group successfully deleted + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -3881,102 +4242,56 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/price-groups/{id}/apply: - put: + delete: tags: - - Price Groups - summary: "Apply price group to charge points, sites or team members" - description: "Required scope: `price-groups:write`" - operationId: apply-price-group + - Installer Jobs + summary: Delete an existing installer job + description: "Required scope: `installer-jobs:delete`" + operationId: delete-installer-job parameters: - - name: id + - name: installerJobId in: path required: true schema: - minimum: 0 - exclusiveMinimum: true type: integer format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ApplyPriceGroup' - required: true responses: + "204": + description: Installer Job deleted "404": - description: Price group not found - content: - application/json: - schema: - $ref: '#/components/schemas/MontaAppResponse' - "200": - description: Price group successfully applied to the selected entities - content: - application/json: - schema: - $ref: '#/components/schemas/PriceGroup' - "400": - description: The request is invalid + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/price-groups/{id}/default: - put: - tags: - - Price Groups - summary: Sets a price group as default - description: "Required scope: `price-groups:write`" - operationId: set-default-price-group - parameters: - - name: id - in: path - required: true - schema: - type: integer - format: int64 - responses: - "404": - description: Price group not found - content: - application/json: - schema: - $ref: '#/components/schemas/MontaAppResponse' - "200": - description: Price group successfully set as default + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/PriceGroup' + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -3987,74 +4302,83 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/prices/forecast: + /api/v1/invoices: get: tags: - - Prices Forecast - summary: Retrieve prices forecast. - description: "Prices can be forecasted for a charge point and optionally a price\ - \ group, when `priceGroupId` is not provided the charge point price group\ - \ will be used.
*Note*: This endpoint is in BETA phase and is subject\ - \ to changes in a near future release

Required scope: `prices-forecast:read`" - operationId: get-prices-forecast + - Invoices + summary: Retrieves a list of invoices by walletId + description: "Required scope: `invoices:read`" + operationId: get-invoice parameters: - - name: chargePointId + - name: page in: query + description: page number to retrieve (starts with 0) schema: - minimum: 0 - exclusiveMinimum: true type: integer - description: Filter to retrieve prices forecast for the specified `chargePointId` - format: int64 - example: 13 - - name: priceGroupId + format: int32 + default: 0 + example: 1 + - name: perPage in: query + description: "number of items per page (between 1 and 100, default 10)" schema: - minimum: 0 - exclusiveMinimum: true type: integer - description: Filter to retrieve prices forecast for the specified `priceGroupId` - format: int64 - nullable: true - example: 130 - - name: teamMemberId + format: int32 + default: 10 + example: 10 + - name: walletId in: query + required: true schema: type: integer - description: Filter to retrieve prices forecast for the specified `teamMemberId` format: int64 - nullable: true - example: 13 + - name: pageable + in: query + required: true + schema: + $ref: "#/components/schemas/Pageable" responses: "200": - description: Prices Forecast for the given filter + description: Invoices successfully retrieved content: application/json: schema: - $ref: '#/components/schemas/PricesForecast' - "401": - description: Unauthorized access + $ref: "#/components/schemas/MontaPage_InvoiceDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - "400": + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": description: The request is invalid content: application/json: @@ -4066,13 +4390,78 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/sites: + /api/v1/invoices/{invoiceId}: get: tags: - - Sites - summary: Retrieve your (charge) sites. - description: "Required scope: `charge-points:read`" - operationId: get-sites + - Invoices + summary: Retrieves an invoice by its id + description: "Required scope: `invoices:read`" + operationId: get-invoice_1 + parameters: + - name: invoiceId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Invoice successfully retrieved + content: + application/json: + schema: + $ref: "#/components/schemas/InvoiceDto" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/nested-teams: + get: + tags: + - Nested teams + summary: Retrieve a list of nested team relations + description: "Required scope: `team-members:read`" + operationId: getNestedTeams parameters: - name: page in: query @@ -4081,7 +4470,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -4089,83 +4478,117 @@ paths: type: integer format: int32 default: 10 - example: "10" - - name: teamId - in: query - description: The team id from which sites will be filtered by - schema: - type: integer - format: int64 - example: "13" - - name: partnerExternalId - in: query - description: "Filter sites by partnerExternalId, to filter only resources\ - \ without `partnerExternalId` *use* `partnerExternalId=\"\"`" - schema: - type: string - - name: sortByLocation + example: 10 + - name: state in: query - description: |- - lat,long coordinates. If supplied, the Charge Points will be sorted in nearest first order relative - to this point. (Format: 55.7096,12.5856) schema: - type: string - example: "55.7096,12.5856" + description: State of the nested team invitation + nullable: true + example: accepted + allOf: + - $ref: "#/components/schemas/TeamMemberState" + - {} - name: includeDeleted in: query - description: Includes deleted resources in the response - required: false schema: type: boolean + description: Includes deleted resources in the response + nullable: true + example: false default: false responses: "200": - description: List of sites that match the criteria + description: List of nested team relations that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_SiteDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_NestedTeamDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] + /api/v1/nested-teams/invite: post: tags: - - Sites - summary: Create a (charge) site - description: "Required scope: `charge-points:write`" - operationId: post-site + - Nested teams + summary: Nested team invite + description: "Required scope: `team-members:write`" + operationId: invite requestBody: content: application/json: schema: - $ref: '#/components/schemas/CreateSite' + $ref: "#/components/schemas/NestedTeamInvite" required: true responses: - "201": - description: Site created + "200": + description: Nested team invite sent + content: + application/json: + schema: + $ref: "#/components/schemas/NestedTeam" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found content: application/json: schema: - $ref: '#/components/schemas/Site' + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -4186,49 +4609,31 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/sites/{siteId}: + /api/v1/nested-teams/{relationId}: get: tags: - - Sites - summary: Retrieve a single (charge) site. - description: "Required scope: `charge-points:read`" - operationId: get-site + - Nested teams + summary: Get a nested team by nested team relation id + description: "Required scope: `team-members:read`" + operationId: getNestedTeam parameters: - - name: siteId + - name: relationId in: path required: true schema: + minimum: 0 + exclusiveMinimum: true type: integer format: int64 responses: "200": - description: Site with provided id + description: Nested team relation content: application/json: schema: - $ref: '#/components/schemas/Site' - "403": - description: Operator doesn't have access to resource - content: - application/json: - schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/NestedTeam" "404": description: Entity with the provided id was not found content: @@ -4241,45 +4646,16 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - delete: - tags: - - Sites - summary: Delete an existing (charge) site - description: "*Note:* This action will also remove `Charge Points` from the\ - \ `Site`.

Required scope: `charge-points:delete`" - operationId: delete-site - parameters: - - name: siteId - in: path - required: true - schema: - type: integer - format: int64 - responses: - "204": - description: Site deleted + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -4300,44 +4676,48 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - patch: + delete: tags: - - Sites - summary: Patch an existing (charge) site - description: "Required scope: `charge-points:write`" - operationId: patch-site + - Nested teams + summary: Delete a nested team relation + description: "Required scope: `team-members:delete`" + operationId: deleteNestedTeam parameters: - - name: siteId + - name: relationId in: path required: true schema: + minimum: 0 + exclusiveMinimum: true type: integer format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/PatchSite' - required: true responses: - "200": - description: Site updated + "204": + description: Nested team relation deleted + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found content: application/json: schema: - $ref: '#/components/schemas/Site' + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -4358,120 +4738,58 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/sponsored-charge-points: - get: + patch: tags: - - Sponsored Charge Points - summary: Retrieve a list of sponsored charge points - description: "Required scope: `sponsored-charge-points:read`" - operationId: get-sponsored-charge-points + - Nested teams + summary: Update a nested team relation + description: "Required scope: `team-members:write`" + operationId: updateNestedTeam parameters: - - name: page - in: query - description: page number to retrieve (starts with 0) - schema: - type: integer - format: int32 - default: 0 - example: "1" - - name: perPage - in: query - description: "number of items per page (between 1 and 100, default 10)" - schema: - type: integer - format: int32 - default: 10 - example: "10" - - name: chargePointId - in: query - schema: - required: - - "false" - type: integer - description: Allows to filter list of sponsored charge points by a charge - point id - format: int64 - nullable: true - example: 13 - - name: teamId - in: query + - name: relationId + in: path + required: true schema: - required: - - "false" + minimum: 0 + exclusiveMinimum: true type: integer - description: Allows to filter list of sponsored charge points by a team - id. format: int64 - nullable: true - example: 19 - - name: includeDeleted - in: query - schema: - type: boolean - description: Filter to include deleted entities in the response - example: false + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PatchNestedTeam" + required: true responses: "200": - description: List of sponsored charges points that match the criteria + description: Nested team invite sent content: application/json: schema: - $ref: '#/components/schemas/MontaPage_SponsoredChargePointDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/NestedTeam" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - post: - tags: - - Sponsored Charge Points - summary: Create a sponsored charge point - description: "Creates a sponsored charge point for a given user, the sponsorship\ - \ is automatically approved.

*Note:* a charge point can only be sponsored\ - \ to one user_id
Required scope: `sponsored-charge-points:write`" - operationId: post-sponsored-charge-point - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSponsoredChargePointDto' - required: true - responses: - "201": - description: Sponsored charge point created - content: - application/json: - schema: - $ref: '#/components/schemas/SponsoredChargePoint' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -4492,49 +4810,31 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/sponsored-charge-points/{sponsoredChargePointId}: - get: + /api/v1/nested-teams/{relationId}/accept-invite: + post: tags: - - Sponsored Charge Points - summary: Retrieve a single sponsored charge point - description: "Required scope: `sponsored-charge-points:read`" - operationId: get-sponsored-charge-point + - Nested teams + summary: Accept a nested team invitation + description: "Required scope: `team-members:write`" + operationId: acceptInvite parameters: - - name: sponsoredChargePointId + - name: relationId in: path required: true schema: + minimum: 0 + exclusiveMinimum: true type: integer format: int64 responses: "200": - description: Sponsored charge point with provided id - content: - application/json: - schema: - $ref: '#/components/schemas/SponsoredChargePoint' - "403": - description: Operator doesn't have access to resource + description: Nested team relation content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/NestedTeam" "404": description: Entity with the provided id was not found content: @@ -4547,44 +4847,16 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - delete: - tags: - - Sponsored Charge Points - summary: Delete an existing sponsored charge point - description: "Required scope: `sponsored-charge-points:delete`" - operationId: delete-sponsored-charge-point - parameters: - - name: sponsoredChargePointId - in: path - required: true - schema: - type: integer - format: int64 - responses: - "204": - description: Sponsored Charge Point deleted + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -4605,82 +4877,91 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - patch: + /api/v1/nested-teams/{relationId}/reject-invite: + post: tags: - - Sponsored Charge Points - summary: Update a sponsored charge point - description: "Required scope: `sponsored-charge-points:write`" - operationId: patch-sponsored-charge-point + - Nested teams + summary: Reject a nested team invitation + description: "Required scope: `team-members:write`" + operationId: rejectInvite parameters: - - name: sponsoredChargePointId + - name: relationId in: path required: true schema: + minimum: 0 + exclusiveMinimum: true type: integer format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/PatchSponsoredChargePoint' - required: true responses: "200": - description: Updated sponsored charge point with provided id + description: Nested team relation content: application/json: schema: - $ref: '#/components/schemas/SponsoredChargePoint' - "400": - description: The request is invalid + $ref: "#/components/schemas/NestedTeam" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/subscription-purchases: - get: - tags: - - Subscription Purchases - summary: Retrieve a list of subscription purchases - description: "Required scope: `subscriptions:read`" - operationId: get-subscription-purchases - parameters: - - name: page - in: query - description: page number to retrieve (starts with 0) - schema: - type: integer - format: int32 + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/operators: + get: + tags: + - Operators + summary: Retrieve operators + description: "Required scope: `operators`" + operationId: get-operators + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -4688,64 +4969,67 @@ paths: type: integer format: int32 default: 10 - example: "10" - - name: subscriptionId - in: query - schema: - required: - - "false" - type: integer - description: Filter subscription purchases by subscription id - format: int64 - nullable: true - example: 1 - - name: includeDeleted - in: query - schema: - required: - - "false" - type: boolean - description: Includes deleted resources in the response - nullable: true - example: true + example: 10 responses: "200": - description: List of subscription purchases that match the criteria + description: List of operators that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_SubscriptionPurchaseDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_OperatorDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/subscription-purchases/{subscriptionPurchaseId}: + /api/v1/operators/{id}: get: tags: - - Subscription Purchases - summary: Retrieve a subscription purchase - description: "Required scope: `subscriptions:read`" - operationId: get-subscription-purchase + - Operators + summary: Retrieve an operator + description: "Required scope: `operators`" + operationId: get-operator parameters: - - name: subscriptionPurchaseId + - name: id in: path required: true schema: @@ -4753,40 +5037,62 @@ paths: format: int64 responses: "200": - description: Subscription purchase with provided id + description: operator with provided id content: application/json: schema: - $ref: '#/components/schemas/SubscriptionPurchase' - "400": - description: The request is invalid + $ref: "#/components/schemas/Operator" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/subscriptions: + /api/v1/payment-terminals: get: tags: - - Subscriptions - summary: Retrieve a list of subscriptions - description: "Required scope: `subscriptions:read`" - operationId: get-subscriptions + - Payment Terminals + summary: Retrieve a list of payment terminals + description: "Required scope: `payment-terminals:read`" + operationId: get-payment-terminals parameters: - name: page in: query @@ -4795,7 +5101,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -4803,86 +5109,74 @@ paths: type: integer format: int32 default: 10 - example: "10" - - name: planId + example: 10 + - name: serial in: query schema: required: - "false" - type: integer - description: Filter subscription by plan - format: int64 + type: string + description: Allows to filter list of terminals by a serial nullable: true - example: 1 - - name: chargePointId + example: XYZ123-DF-123 + - name: teamId in: query schema: required: - "false" type: integer - description: Filter subscriptions by charge point + description: Allows to filter list of terminals by a team id. format: int64 nullable: true - example: 1 - - name: subscriptionPurchaseId + example: 19 + - name: includeDeleted in: query schema: required: - "false" - type: integer - description: Filter subscriptions by subscription purchase id. Should return - max. 1 subscription. - format: int64 + type: boolean + description: "If true, deleted entities will be included in the response." nullable: true - example: 42 + example: true responses: "200": - description: List of Charge Point subscriptions that match the criteria + description: List of payment terminals that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_SubscriptionDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_PaymentTerminalDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - post: - tags: - - Subscriptions - summary: Create subscription - description: "Required scope: `subscriptions:write`" - operationId: create-subscription - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSubscription' - required: true - responses: - "201": - description: The created subscription + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/Subscription' + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -4893,81 +5187,60 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/subscriptions/{subscriptionId}: + /api/v1/payment-terminals/{paymentTerminalId}: get: tags: - - Subscriptions - summary: Retrieve a subscription - description: "Required scope: `subscriptions:read`" - operationId: get-subscription + - Payment Terminals + summary: Retrieve a single payment terminal + description: "Required scope: `payment-terminals:read`" + operationId: get-payment-terminal parameters: - - name: subscriptionId + - name: paymentTerminalId in: path required: true schema: - type: integer - format: int64 + type: string responses: "200": - description: Subscription with provided ID + description: Payment Terminal with provided id content: application/json: schema: - $ref: '#/components/schemas/Subscription' - "400": - description: The request is invalid + $ref: "#/components/schemas/PaymentTerminal" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - delete: - tags: - - Subscriptions - summary: Cancel subscription - description: "Required scope: `subscriptions:delete`" - operationId: delete-subscription - parameters: - - name: subscriptionId - in: path - required: true - schema: - type: integer - format: int64 - responses: - "204": - description: Subscription successfully canceled + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/Unit' + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -4978,100 +5251,104 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/subscriptions/{subscriptionId}/approve: - post: + /api/v1/plans: + get: tags: - - Subscriptions - summary: Approve subscription - description: "Required scope: `subscriptions:write`" - operationId: approve-subscription + - Plans + summary: Retrieve plans + description: "Required scope: `plans:read`" + operationId: get-plans parameters: - - name: subscriptionId - in: path - required: true + - name: page + in: query + description: page number to retrieve (starts with 0) schema: type: integer - format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ApproveSubscription' - required: true + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 responses: "200": - description: The updated subscription + description: List of plans that match the criteria content: application/json: schema: - $ref: '#/components/schemas/Subscription' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_PlanDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/tariff-period-groups: + /api/v1/plans/{id}: get: tags: - - Tariff Period Groups - summary: Retrieve Tariff Period Groups by tariff id - description: "Required scope: `tariff:read`" - operationId: get-period-groups + - Plans + summary: Retrieve a plan + description: "Required scope: `plans:read`" + operationId: get-plan parameters: - - name: tariffId - in: query - description: Filter to retrieve tariff period groups by tariff id + - name: id + in: path + required: true schema: type: integer format: int64 responses: "200": - description: Tariff period group with provided tariff id - content: - application/json: - schema: - type: array - items: - $ref: '#/components/schemas/TariffPeriodGroup' - "403": - description: Operator doesn't have access to resource + description: Plan with provided id content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/Plan" "404": description: Entity with the provided id was not found content: @@ -5084,47 +5361,26 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - post: - tags: - - Tariff Period Groups - summary: Create a new Tariff Period Group. - description: "Required scope: `tariffs:write`" - operationId: create-tariff-period-group - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/TariffPeriodGroup' - required: true - responses: - "201": - description: New Tariff Period Group + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/TariffPeriodGroup' + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -5135,50 +5391,40 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/tariff-period-groups/{id}: + /api/v1/price-group-tags: get: tags: - - Tariff Period Groups - summary: Retrieve Tariff Period Groups by id - description: "Required scope: `tariff:read`" - operationId: get-period-group + - Price Groups Tags + summary: Retrieve price group tags. + description: "Required scope: `price-groups:read`" + operationId: get-price-group-tags parameters: - - name: id - in: path - description: Filter to retrieve tariff period groups by id - required: true + - name: name + in: query schema: - type: integer - format: int64 + type: string + description: Filter to retrieve resources by the specified `name`. + nullable: true + example: Energy + - name: partnerExternalId + in: query + schema: + required: + - "false" + type: string + description: "Filter resources by partnerExternalId, to filter only resources\ + \ without `partnerExternalId` *use* `partnerExternalId=\"\"`" + nullable: true + example: 1A2B responses: "200": - description: Tariff period group with provided group id - content: - application/json: - schema: - $ref: '#/components/schemas/TariffPeriodGroup' - "403": - description: Operator doesn't have access to resource + description: Price group tags for a given filter content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/MontaPage_PriceGroupTagDto_" "404": description: Entity with the provided id was not found content: @@ -5191,45 +5437,26 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - delete: - tags: - - Tariff Period Groups - summary: "Delete an existing Tariff Period Group, and all contained recurring\ - \ periods and prices." - description: "Required scope: `tariffs:delete`" - operationId: delete-tariff-period-group - parameters: - - name: id - in: path - required: true - schema: - type: integer - format: int64 - responses: - "204": - description: Tariff Period Group deleted + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -5240,151 +5467,124 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - patch: + post: tags: - - Tariff Period Groups - summary: Update existing Tariff Period Group. - description: "Required scope: `tariffs:write`" - operationId: update-tariff-period-group - parameters: - - name: id - in: path - required: true - schema: - type: integer - format: int64 + - Price Groups Tags + summary: Create a price group tag + description: "Required scope: `price-groups:write`" + operationId: post-price-group-tag requestBody: content: application/json: schema: - $ref: '#/components/schemas/TariffPeriodGroup' + $ref: "#/components/schemas/CreatePriceGroupTag" required: true responses: - "200": - description: Updated Tariff Period Group + "201": + description: Price group tag created content: application/json: schema: - $ref: '#/components/schemas/TariffPeriodGroup' - "400": - description: The request is invalid + $ref: "#/components/schemas/PriceGroupTag" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/tariff-recurring-periods: + /api/v1/price-group-tags/{id}: get: tags: - - Tariff Recurring Periods - summary: Retrieve recurring periods. - description: "Required scope: `tariffs:read`" - operationId: get-tariff-recurring-periods + - Price Groups Tags + summary: Retrieve a single price group tag + description: "Required scope: `price-groups:read`" + operationId: get-price-group-tag parameters: - - name: page - in: query - description: page number to retrieve (starts with 0) - schema: - type: integer - format: int32 - default: 0 - example: "1" - - name: perPage - in: query - description: "number of items per page (between 1 and 100, default 10)" - schema: - type: integer - format: int32 - default: 10 - example: "10" - - name: tariffId - in: query - required: true - schema: - type: integer - format: int64 - - name: tariffPeriodGroupId - in: query + - name: id + in: path required: true schema: type: integer format: int64 responses: "200": - description: Tariff recurring periods with provided tariffId & tariffPeriodGroupId + description: Price group tag with provided id content: application/json: schema: - $ref: '#/components/schemas/Page_TariffRecurringPeriodDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/PriceGroupTag" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - post: - tags: - - Tariff Recurring Periods - summary: Create new recurring period. - description: "Required scope: `tariffs:write`" - operationId: create-tariff-recurring-periods - parameters: [] - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/TariffRecurringPeriodCreateRequestDto' - required: true - responses: - "201": - description: Tariff recurring period that was created + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/TariffRecurringPeriod' + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -5395,25 +5595,14 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/tariff-recurring-periods/{id}: delete: tags: - - Tariff Recurring Periods - summary: "Delete an existing Tariff Recurring Period , and all contained prices." - description: "Required scope: `tariffs:delete`" - operationId: delete-tariff-recurring-period + - Price Groups Tags + summary: Delete an existing price group tag + description: "Required scope: `price-groups:delete`" + operationId: delete-price-group-tag parameters: - name: id in: path @@ -5422,51 +5611,78 @@ paths: type: integer format: int64 responses: - "204": - description: Tariff Recurring Period deleted - "400": - description: The request is invalid + "200": + description: Price group tag deleted + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/tariff-recurring-periods/{periodId}: - get: + patch: tags: - - Tariff Recurring Periods - summary: Retrieve a tariff recurring period. - description: "Required scope: `tariffs:read`" - operationId: get-tariff-recurring-period + - Price Groups Tags + summary: Update a price group tag + description: "Required scope: `price-groups:write`" + operationId: patch-price-group-tag parameters: - - name: periodId + - name: id in: path required: true schema: type: integer format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PatchPriceGroupTag" + required: true responses: "200": - description: Tariff recurring period with provided id + description: Price group tag updated content: application/json: schema: - $ref: '#/components/schemas/TariffRecurringPeriod' + $ref: "#/components/schemas/PriceGroupTag" "404": description: Entity with the provided id was not found content: @@ -5479,54 +5695,26 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - patch: - tags: - - Tariff Recurring Periods - summary: Update existing recurring period. - description: "Required scope: `tariffs:write`" - operationId: update-tariff-recurring-periods - parameters: - - name: periodId - in: path - required: true - schema: - type: integer - format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/TariffRecurringPeriodUpdateRequestDto' - required: true - responses: - "200": - description: Tariff recurring period that was updated - content: - application/json: - schema: - $ref: '#/components/schemas/TariffRecurringPeriod' + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -5537,79 +5725,30 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/tariffs: + /api/v1/price-groups: get: tags: - - Tariff - summary: Retrieve all tariffs. - description: "Required scope: `tariffs:read`" - operationId: get-all-tariffs + - Price Groups + summary: Retrieve a list of price groups. + description: "Required scope: `price-groups:read`" + operationId: getPriceGroups parameters: - - name: countryId - in: query - description: Country id of the tariff - schema: - type: integer - format: int64 - - name: countryAreaId - in: query - description: Country area id of the tariff - schema: - type: integer - format: int64 - - name: externalId - in: query - description: External id of the tariff - schema: - type: string - - name: operatorId - in: query - description: Operator id of the tariff (taken from the consumer) - schema: - type: integer - format: int64 - name: teamId in: query - description: Team id of the tariff + description: Filter to retrieve price groups with specified team id + required: true schema: type: integer format: int64 - - name: zip - in: query - description: Zip code of the tariff - schema: - type: string responses: "200": - description: All tariffs - content: - application/json: - schema: - type: array - items: - $ref: '#/components/schemas/TariffDto' - "403": - description: Operator doesn't have access to resource + description: List of price groups that match the criteria content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/MontaPage_PriceGroupDto_" "404": description: Entity with the provided id was not found content: @@ -5622,94 +5761,100 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] post: tags: - - Tariff - summary: Create a new Tariff. - description: "Required scope: `tariffs:write`" - operationId: create-tariff + - Price Groups + summary: Creates a price group + description: "Required scope: `price-groups:write`" + operationId: create-price-group requestBody: content: application/json: schema: - $ref: '#/components/schemas/CreateTariffRequest' + $ref: "#/components/schemas/CreateOrUpdatePriceGroupDto" required: true responses: + "404": + description: Team not found + content: + application/json: + schema: + $ref: "#/components/schemas/MontaAppResponse" "201": - description: New Tariff + description: Price group successfully created + "401": + description: Consumer with provided credentials was not found content: application/json: schema: - $ref: '#/components/schemas/TariffDto' - "400": - description: The request is invalid + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/tariffs/{tariffId}: + /api/v1/price-groups/{id}: get: tags: - - Tariff - summary: Retrieve your tariff and prices. - description: "Required scope: `tariffs:read`" - operationId: get-tariff + - Price Groups + summary: Retrieve a price group. + description: "Required scope: `price-groups:read`" + operationId: getPriceGroup parameters: - - name: start - in: query - description: "Filter to retrieve tariffs where `createdAt` >= `start` (ISO8601:\ - \ yyyy-MM-ddTHH:mm:ssZ)" - schema: - type: string - format: date-time - example: 2022-05-22T09:30:03Z - - name: end - in: query - description: "Filter to retrieve charges where `createdAt` <= `end` (ISO8601:\ - \ yyyy-MM-ddTHH:mm:ssZ)" - schema: - type: string - format: date-time - example: 2022-05-22T09:30:03Z - - name: tariffId + - name: id in: path required: true schema: @@ -5717,21 +5862,11 @@ paths: format: int64 responses: "200": - description: Tariff with provided id - content: - application/json: - schema: - $ref: '#/components/schemas/FullTariff' - "403": - description: Operator doesn't have access to resource + description: Price group with provided id content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/PriceGroup" "404": description: Entity with the provided id was not found content: @@ -5744,36 +5879,46 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid + "401": + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] put: tags: - - Tariff - summary: Update an existing Tariff. - description: "Required scope: `tariffs:write`" - operationId: update-tariff + - Price Groups + summary: Updates a price group + description: "Required scope: `price-groups:write`" + operationId: update-price-group parameters: - - name: tariffId + - name: id in: path required: true schema: @@ -5783,64 +5928,31 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/UpdateTariffRequest' + $ref: "#/components/schemas/CreateOrUpdatePriceGroupDto" required: true responses: - "200": - description: Updated Tariff + "404": + description: Price group not found content: application/json: schema: - $ref: '#/components/schemas/TariffDto' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaAppResponse" + "200": + description: Price group successfully updated content: application/json: schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + $ref: "#/components/schemas/PriceGroup" "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/tariffs/{tariffId}/create-prices: - post: - tags: - - Tariff - summary: Create the prices for a given tariff within a given period of time. - description: "Required scope: `tariffs:write`" - operationId: create-tariff-prices - parameters: - - name: tariffId - in: path - required: true - schema: - type: integer - format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateTariffPricesRequest' - required: true - responses: - "201": - description: Tariff prices created - content: - application/json: - schema: - $ref: '#/components/schemas/FullTariff' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -5851,18 +5963,6 @@ paths: status: FORBIDDEN message: Operator doesn't have access to resource errorCode: ACCESS_FORBIDDEN - "404": - description: Entity with the provided id was not found - content: - application/json: - schema: - type: object - example: - status: NOT_FOUND - message: Requested entity/entity provided in body was not found - readableMessage: user friendly message - errorCode: RESOURCE_NOT_FOUND - context: context "400": description: The request is invalid content: @@ -5873,178 +5973,40 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/team-members: - get: + delete: tags: - - Team Members - summary: Retrieve a list of team members. - description: "Required scope: `team-members:read`" - operationId: getTeamMembers + - Price Groups + summary: Deletes a price group + description: "Required scope: `price-groups:delete`" + operationId: delete-price-group parameters: - - name: page - in: query - description: page number to retrieve (starts with 0) - schema: - type: integer - format: int32 - default: 0 - example: "1" - - name: perPage - in: query - description: "number of items per page (between 1 and 100, default 10)" - schema: - type: integer - format: int32 - default: 10 - example: "10" - - name: teamId - in: query - schema: - required: - - "false" - type: integer - description: Filter team members by `teamId` - format: int64 - nullable: true - example: 1 - - name: includeDeleted - in: query - schema: - required: - - "false" - type: boolean - description: Includes deleted resources in the response - example: true - default: false - - name: role - in: query - schema: - nullable: true - allOf: - - $ref: '#/components/schemas/TeamMemberRole' - - description: Filter team members by the specified `role` - example: admin - - name: state - in: query - schema: - nullable: true - allOf: - - $ref: '#/components/schemas/TeamMemberState' - - description: Filter team members by the specified `state` - example: expired - - name: userId - in: query + - name: id + in: path + required: true schema: - minimum: 0 - exclusiveMinimum: true - required: - - "false" type: integer - description: Filter team members with specified `userId` format: int64 - nullable: true - example: 42 - - name: email - in: query - schema: - required: - - "false" - type: string - description: Filter team members with specified `email` - format: email - nullable: true - example: user@acme.com - - name: phone - in: query - schema: - pattern: "^\\+[1-9]\\d{1,14}$" - required: - - "false" - type: string - description: Filter team members with specified `phone` number - nullable: true - example: "+451234567" - - name: partnerExternalTeamId - in: query - schema: - required: - - "false" - type: string - description: "Filter team members by the specified `partnerExternalTeamId`Note:\ - \ partnerExternalTeamId refers to external id on the team level" - nullable: true - example: 1A2B3C4D5E - - name: partnerExternalId - in: query - schema: - required: - - "false" - type: string - description: Filter team members with specified `partnerExternalId` - nullable: true - example: 1A2B3C4D5E responses: - "200": - description: List of team members that match the criteria - content: - application/json: - schema: - $ref: '#/components/schemas/MontaPage_TeamMemberDto_' - "400": - description: The request is invalid + "404": + description: Price group not found content: application/json: schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + $ref: "#/components/schemas/MontaAppResponse" + "204": + description: Price group successfully deleted "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - post: - tags: - - Team Members - summary: Create (invite) a team member - description: "Create (invite) a user to join a team, invitation can be done\ - \ via `userId`, `email` and/or `phone`. A user that does not exist in yet\ - \ will have a null `userId`.

Required scope: `team-members:write`" - operationId: post-team-member - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateTeamMember' - required: true - responses: - "201": - description: Team member created - content: - application/json: - schema: - $ref: '#/components/schemas/TeamMemberDto' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -6065,87 +6027,63 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/team-members/{id}: - get: + /api/v1/price-groups/{id}/apply: + put: tags: - - Team Members - summary: Retrieve a team member. - description: "Required scope: `team-members:read`" - operationId: getTeamMember + - Price Groups + summary: "Apply price group to charge points, sites or team members" + description: "Required scope: `price-groups:write`" + operationId: apply-price-group parameters: - name: id in: path required: true schema: + minimum: 0 + exclusiveMinimum: true type: integer format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ApplyPriceGroup" + required: true responses: - "200": - description: Team member with provided id + "404": + description: Price group not found content: application/json: schema: - $ref: '#/components/schemas/TeamMemberDto' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaAppResponse" + "200": + description: Price group successfully applied to the selected entities content: application/json: schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + $ref: "#/components/schemas/PriceGroup" "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - patch: - tags: - - Team Members - summary: Patch a team member. - description: "Required scope: `team-members:write`" - operationId: patchTeamMember - parameters: - - name: id - in: path - required: true - schema: - type: integer - format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/PatchTeamMember' - required: true - responses: - "200": - description: Updated Team member with provided id + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource content: application/json: schema: - $ref: '#/components/schemas/TeamMemberDto' + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -6156,25 +6094,15 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/team-members/{id}/resend-invite: - post: + /api/v1/price-groups/{id}/default: + put: tags: - - Team Members - summary: Resend an invite to a team member and reset expiry date. - description: "Required scope: `team-members:write`" - operationId: resendTeamMemberInvite + - Price Groups + summary: Sets a price group as default + description: "Required scope: `price-groups:write`" + operationId: set-default-price-group parameters: - name: id in: path @@ -6183,51 +6111,28 @@ paths: type: integer format: int64 responses: - "200": - description: Team member with provided id + "404": + description: Price group not found content: application/json: schema: - $ref: '#/components/schemas/TeamMemberDto' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaAppResponse" + "200": + description: Price group successfully set as default content: application/json: schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + $ref: "#/components/schemas/PriceGroup" "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/team-members/{teamMemberId}: - delete: - tags: - - Team Members - summary: Delete an existing team member - description: "Required scope: `team-members:delete`" - operationId: delete-team-member - parameters: - - name: teamMemberId - in: path - required: true - schema: - type: integer - format: int64 - responses: - "204": - description: Team member deleted + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -6248,104 +6153,75 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/teams: + /api/v1/prices/forecast: get: tags: - - Teams - summary: Retrieve a list of teams - description: "Required scope: `teams:read`" - operationId: get-teams + - Prices Forecast + summary: Retrieve prices forecast. + description: "Prices can be forecasted for a charge point and optionally a price\ + \ group, when `priceGroupId` is not provided the charge point price group\ + \ will be used.
*Note*: This endpoint is in BETA phase and is subject\ + \ to changes in a near future release

Required scope: `prices-forecast:read`" + operationId: get-prices-forecast parameters: - - name: partnerExternalId - in: query - description: "Filter teams by partnerExternalId, to filter only resources\ - \ without `partnerExternalId` *use* `partnerExternalId=\"\"`" - schema: - type: string - - name: includeDeleted + - name: chargePointId in: query - description: Filter to include delete teams in the response - required: false schema: - type: boolean - default: false - example: "true" - - name: page + minimum: 0 + exclusiveMinimum: true + type: integer + description: Filter to retrieve prices forecast for the specified `chargePointId` + format: int64 + example: 13 + - name: priceGroupId in: query - description: page number to retrieve (starts with 0) schema: + minimum: 0 + exclusiveMinimum: true type: integer - format: int32 - default: 0 - example: "1" - - name: perPage + description: Filter to retrieve prices forecast for the specified `priceGroupId` + format: int64 + nullable: true + example: 130 + - name: teamMemberId in: query - description: "number of items per page (between 1 and 100, default 10)" schema: type: integer - format: int32 - default: 10 - example: "10" + description: Filter to retrieve prices forecast for the specified `teamMemberId` + format: int64 + nullable: true + example: 13 responses: "200": - description: List of teams that match the criteria + description: Prices Forecast for the given filter content: application/json: schema: - $ref: '#/components/schemas/MontaPage_TeamDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/PricesForecast" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - post: - tags: - - Teams - summary: Create a team - description: "Required scope: `teams:write`" - operationId: post-team - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateTeamDto' - required: true - responses: - "201": - description: Team created - content: - application/json: - schema: - $ref: '#/components/schemas/Team' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -6366,79 +6242,122 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/teams/{id}: + /api/v1/reports: get: tags: - - Teams - summary: Retrieve a team - description: "Required scope: `teams:read`" - operationId: get-team + - Reports + summary: Retrieve a list of reports for charge point(s). + description: "Required scope: `reports:read`" + operationId: get-reports parameters: - - name: id - in: path - required: true + - name: page + in: query + description: page number to retrieve (starts with 0) schema: type: integer - format: int64 - responses: - "200": - description: Team with provided id - content: - application/json: - schema: - $ref: '#/components/schemas/Team' - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/teams/{teamId}: - delete: - tags: - - Teams - summary: Delete an existing team - description: "Required scope: `teams:delete`" - operationId: delete-team - parameters: - - name: teamId - in: path - required: true + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" schema: type: integer - format: int64 - responses: - "204": - description: Team deleted - "403": + format: int32 + default: 10 + example: 10 + - name: chargePointId + in: query + schema: + required: + - "false" + type: integer + description: Filter to retrieve reports with specified `chargePointId` + format: int64 + nullable: true + example: 10 + - name: state + in: query + schema: + required: + - "false" + type: string + description: Filter to retrieve reports by `state` + nullable: true + example: new + enum: + - new + - action + - assigned-owner + - assigned-monta + - assigned-operator + - resolved + - name: fromDate + in: query + schema: + required: + - "false" + type: string + description: "Filter to retrieve reports where `createdAt` >= `fromDate`\ + \ (ISO8601: yyyy-MM-ddTHH:mm:ssZ)" + format: date-time + nullable: true + example: 2022-05-22T09:30:03Z + - name: toDate + in: query + schema: + required: + - "false" + type: string + description: "Filter to retrieve reports where `createdAt` <= `toDate` (ISO8601:\ + \ yyyy-MM-ddTHH:mm:ssZ)" + format: date-time + nullable: true + example: 2022-05-22T09:30:03Z + - name: priority + in: query + schema: + required: + - "false" + type: string + description: Priority of the report + nullable: true + enum: + - low + - medium + - high + responses: + "200": + description: List of reports that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_ReportDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": description: Operator doesn't have access to resource content: application/json: @@ -6458,44 +6377,29 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - patch: + /api/v1/reports/{reportId}: + get: tags: - - Teams - summary: Patch an existing team - description: "Required scope: `teams:write`" - operationId: patch-team + - Reports + summary: Retrieve a report related to a charge point. + description: "Required scope: `reports:read`" + operationId: get-report parameters: - - name: teamId + - name: reportId in: path required: true schema: type: integer format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/PatchTeam' - required: true responses: "200": - description: Team updated + description: report with provided id content: application/json: schema: - $ref: '#/components/schemas/Team' + $ref: "#/components/schemas/ReportDto" "403": description: Operator doesn't have access to resource content: @@ -6506,35 +6410,48 @@ paths: status: FORBIDDEN message: Operator doesn't have access to resource errorCode: ACCESS_FORBIDDEN - "400": - description: The request is invalid + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/wallet-transactions: + /api/v1/sites: get: tags: - - Wallet Transactions - summary: Retrieve your wallet transactions. - description: "Required scope: `wallet-transactions:read`" - operationId: get-wallet-transactions + - Sites + summary: Retrieve your (charge) sites + description: "Required scope: `charge-points:read`
Organization authorization:\ + \ `supported`" + operationId: get-sites parameters: - name: page in: query @@ -6543,7 +6460,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -6551,131 +6468,85 @@ paths: type: integer format: int32 default: 10 - example: "10" + example: 10 - name: teamId in: query schema: type: integer - description: "Filter to retrieve transactions for a given team. *Note*:\ - \ When not provided the transactions for the operator will be returned\ - \ instead" - format: int32 - nullable: true - example: 1 - - name: fromDate - in: query - schema: - pattern: "^(\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2})Z$" - type: string - description: "Filter to retrieve transactions where `createdAt` >= `fromDate`\ - \ (ISO8601: yyyy-MM-ddTHH:mm:ssZ)" - format: date-time - nullable: true - example: 2022-05-22T09:30:03Z - - name: toDate - in: query - schema: - pattern: "^(\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2})Z$" - type: string - description: "Filter to retrieve transactions where `createdAt` <= `toDate`\ - \ (ISO8601: yyyy-MM-ddTHH:mm:ssZ)" - format: date-time + description: Allows to filter by a team id. + format: int64 nullable: true - example: 2022-05-22T09:30:03Z - - name: referenceId + example: 19 + - name: partnerExternalId in: query schema: type: string - description: Filter to retrieve transactions by the matching referenceId + description: "Filter by partnerExternalId, to filter only resources without\ + \ `partnerExternalId` *use* `partnerExternalId=\"\"`" nullable: true example: "1" - - name: referenceType + - name: sortByLocation in: query schema: + pattern: "^(-?\\d*\\.\\d+|\\d+\\.\\d*)(,)(-?\\d*\\.\\d+|\\d+\\.\\d*)$" + type: string + description: "lat,long coordinates. If supplied, the Charge Points will\ + \ be sorted in nearest first order relativeto this point. (Format: 55.7096,12.5856,\ + \ -8.050000, -34.900002)" nullable: true - allOf: - - $ref: '#/components/schemas/WalletTransactionReferenceType' - - type: string - description: Filter to retrieve transactions by the matching referenceType - example: CHARGE - - name: state + example: "55.7096,12.5856" + - name: operatorId in: query schema: + type: integer + description: Allows to filter by `operatorId` + format: int64 nullable: true - allOf: - - $ref: '#/components/schemas/WalletTransactionState' - - type: string - description: Filter to retrieve transactions by the matching state - example: complete - - name: group + example: 1 + - name: includePublic in: query schema: - nullable: true - allOf: - - $ref: '#/components/schemas/WalletTransactionGroup' - - type: string - description: Filter to retrieve transactions by the matching group - example: deposit - - name: partnerExternalId + type: boolean + description: "Includes public sites from other operators in the response
**Note:\ + \ Only supported from Version `2024-07-01`**" + example: false + default: false + - name: includeDeleted in: query schema: - required: - - "false" - type: string - description: "Filter transactions by partnerExternalId, to filter only resources\ - \ without `partnerExternalId` *use* `partnerExternalId=\"\"`" - nullable: true - example: "1" + type: boolean + description: Includes deleted resources in the response + example: true + default: false responses: "200": - description: List of wallet transactions that match the criteria + description: List of sites that match the criteria content: application/json: schema: - $ref: '#/components/schemas/MontaPage_WalletTransactionDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/MontaPage_SiteDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/wallet-transactions/operator-adjustment-transaction: - post: - tags: - - Wallet Transactions - summary: Post an operator adjustment transaction - description: "This API endpoint is for operator to create an adjustment transaction\ - \ to their teams. Required scope: `wallet-transaction:write`" - operationId: post-operator-adjustment-transaction - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/OperatorAdjustmentTransaction' - required: true - responses: - "201": - description: Transaction created - content: - application/json: - schema: - $ref: '#/components/schemas/WalletTransaction' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -6696,49 +6567,28 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/wallet-transactions/{transactionId}: - get: + post: tags: - - Wallet Transactions - summary: Retrieve a single wallet transaction. - description: "Required scope: `wallet-transactions:read`" - operationId: get-wallet-transaction - parameters: - - name: transactionId - in: path + - Sites + summary: Create a (charge) site + description: "Required scope: `charge-points:write`
Organization authorization:\ + \ `supported`" + operationId: post-site + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateSite" required: true - schema: - type: integer - format: int64 responses: - "200": - description: Wallet transaction with provided id - content: - application/json: - schema: - $ref: '#/components/schemas/WalletTransaction' - "403": - description: Operator doesn't have access to resource + "201": + description: Site created content: application/json: schema: - type: object - example: - status: FORBIDDEN - message: Operator doesn't have access to resource - errorCode: ACCESS_FORBIDDEN + $ref: "#/components/schemas/Site" "404": description: Entity with the provided id was not found content: @@ -6751,54 +6601,16 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - patch: - tags: - - Wallet Transactions - summary: Patch an existing transaction - description: "Required scope: `transaction:write`" - operationId: patch-transaction - parameters: - - name: transactionId - in: path - required: true - schema: - type: integer - format: int64 - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/PatchWalletTransaction' - required: true - responses: - "200": - description: Transaction updated - content: - application/json: - schema: - $ref: '#/components/schemas/WalletTransaction' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -6819,110 +6631,52 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/wallets: + /api/v1/sites/{siteId}: get: tags: - - Wallets - summary: Retrieve your wallets. - description: "Required scope: `wallet-transactions:read`" - operationId: get-wallets + - Sites + summary: Retrieve a single (charge) site + description: "Required scope: `charge-points:read`
Organization authorization:\ + \ `supported`" + operationId: get-site parameters: - - name: page - in: query - description: page number to retrieve (starts with 0) - schema: - type: integer - format: int32 - default: 0 - example: "1" - - name: perPage - in: query - description: "number of items per page (between 1 and 100, default 10)" - schema: - type: integer - format: int32 - default: 10 - example: "10" - - name: teamId - in: query - schema: - type: integer - description: "Filter to retrieve wallet for a given team. *Note*: You need\ - \ to either provide `teamId` or `operatorId`" - format: int32 - nullable: true - example: 1 - - name: operatorId - in: query + - name: siteId + in: path + required: true schema: type: integer - description: "Filter to retrieve wallet for a given operator. *Note*: You\ - \ need to either provide `teamId` or `operatorId`" - format: int32 - nullable: true - example: 1 + format: int64 responses: "200": - description: List of wallets that match the criteria + description: Site with provided id content: application/json: schema: - $ref: '#/components/schemas/MontaPage_WalletDto_' - "400": - description: The request is invalid + $ref: "#/components/schemas/Site" + "404": + description: Entity with the provided id was not found content: application/json: schema: type: object example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": - description: Unauthorized access + description: Consumer with provided credentials was not found content: application/json: schema: type: object example: status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN - security: - - BearerAccessToken: [] - /api/v1/wallets/{walletId}: - get: - tags: - - Wallets - summary: Retrieve a single wallet. - description: "Required scope: `wallet-transactions:read`" - operationId: get-wallet - parameters: - - name: walletId - in: path - required: true - schema: - type: integer - format: int64 - responses: - "200": - description: Wallet with provided id - content: - application/json: - schema: - $ref: '#/components/schemas/Wallet' + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND "403": description: Operator doesn't have access to resource content: @@ -6933,18 +6687,6 @@ paths: status: FORBIDDEN message: Operator doesn't have access to resource errorCode: ACCESS_FORBIDDEN - "404": - description: Entity with the provided id was not found - content: - application/json: - schema: - type: object - example: - status: NOT_FOUND - message: Requested entity/entity provided in body was not found - readableMessage: user friendly message - errorCode: RESOURCE_NOT_FOUND - context: context "400": description: The request is invalid content: @@ -6955,34 +6697,38 @@ paths: status: BAD_REQUEST message: Invalid request errorCode: BAD_REQUEST - "401": - description: Unauthorized access - content: - application/json: - schema: - type: object - example: - status: UNAUTHORIZED - message: Invalid or expired `accessToken`. - errorCode: INVALID_ACCESS_TOKEN security: - BearerAccessToken: [] - /api/v1/webhooks/config: - get: + delete: tags: - - Webhooks - summary: Get your webhook config - description: "Required scope: `manage-webhooks:read`" - operationId: get-webhook-config + - Sites + summary: Delete an existing (charge) site + description: "*Note:* This action will also remove `Charge Points` from the\ + \ `Site`.

Required scope: `charge-points:delete`
Organization\ + \ authorization: `supported`" + operationId: delete-site + parameters: + - name: siteId + in: path + required: true + schema: + type: integer + format: int64 responses: - "200": - description: Your Webhook config. + "204": + description: Site deleted + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/WebhookConfig' - "404": - description: Webhook config not found. + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": description: Consumer with provided credentials was not found content: @@ -6993,6 +6739,16 @@ paths: status: UNAUTHORIZED message: Consumer with given `clientId` and `clientSecret` not found errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -7005,25 +6761,45 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] - put: + patch: tags: - - Webhooks - summary: Update your webhook config - description: "Required scope: `manage-webhooks:write`" - operationId: update-webhook-config + - Sites + summary: Patch an existing (charge) site + description: "Required scope: `charge-points:write`
Organization authorization:\ + \ `supported`" + operationId: patch-site + parameters: + - name: siteId + in: path + required: true + schema: + type: integer + format: int64 requestBody: content: application/json: schema: - $ref: '#/components/schemas/WebhookConfig' + $ref: "#/components/schemas/PatchSite" required: true responses: "200": - description: Webhook config successfully updated. + description: Site updated + content: + application/json: + schema: + $ref: "#/components/schemas/Site" + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/WebhookConfig' + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": description: Consumer with provided credentials was not found content: @@ -7034,37 +6810,16 @@ paths: status: UNAUTHORIZED message: Consumer with given `clientId` and `clientSecret` not found errorCode: CONSUMER_NOT_FOUND - "400": - description: The request is invalid - content: - application/json: - schema: - type: object - example: - status: BAD_REQUEST - message: Invalid request - errorCode: BAD_REQUEST - security: - - BearerAccessToken: [] - delete: - tags: - - Webhooks - summary: Delete webhook config - description: "Required scope: `manage-webhooks:delete`" - operationId: delete-webhook-config - responses: - "204": - description: Successfully deleted webhook configuration - "401": - description: Consumer with provided credentials was not found + "403": + description: Operator doesn't have access to resource content: application/json: schema: type: object example: - status: UNAUTHORIZED - message: Consumer with given `clientId` and `clientSecret` not found - errorCode: CONSUMER_NOT_FOUND + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -7077,14 +6832,13 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/webhooks/entries: + /api/v1/sponsored-charge-points: get: tags: - - Webhooks - summary: Retrieve webhook entries - description: "This endpoint can help you debug pending/failed webhook entries.\ - \ Required scope: `webhooks:read`" - operationId: get-webhook-entries + - Sponsored Charge Points + summary: Retrieve a list of sponsored charge points + description: "Required scope: `sponsored-charge-points:read`" + operationId: get-sponsored-charge-points parameters: - name: page in: query @@ -7093,7 +6847,7 @@ paths: type: integer format: int32 default: 0 - example: "1" + example: 1 - name: perPage in: query description: "number of items per page (between 1 and 100, default 10)" @@ -7101,21 +6855,54 @@ paths: type: integer format: int32 default: 10 - example: "10" - - name: status + example: 10 + - name: chargePointId + in: query + schema: + required: + - "false" + type: integer + description: Allows to filter list of sponsored charge points by a charge + point id + format: int64 + nullable: true + example: 13 + - name: teamId in: query - description: The status from which webhook entries will be filtered by schema: + required: + - "false" type: integer + description: Allows to filter list of sponsored charge points by a team + id. format: int64 - example: failed + nullable: true + example: 19 + - name: includeDeleted + in: query + schema: + type: boolean + description: Filter to include deleted entities in the response + example: false responses: "200": - description: List of webhook entries for your consumer in the past 24 hours + description: List of sponsored charges points that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_SponsoredChargePointDto_" + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/MontaPage_WebhookEntryDto_' + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": description: Consumer with provided credentials was not found content: @@ -7126,6 +6913,16 @@ paths: status: UNAUTHORIZED message: Consumer with given `clientId` and `clientSecret` not found errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -7138,18 +6935,80 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] - /api/v1/webhooks/entries/{entryId}: + post: + tags: + - Sponsored Charge Points + summary: Create a sponsored charge point + description: "Creates a sponsored charge point for a given user, the sponsorship\ + \ is automatically approved.

*Note:* a charge point can only be sponsored\ + \ to one user_id
Required scope: `sponsored-charge-points:write`" + operationId: post-sponsored-charge-point + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateSponsoredChargePointDto" + required: true + responses: + "201": + description: Sponsored charge point created + content: + application/json: + schema: + $ref: "#/components/schemas/SponsoredChargePoint" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/sponsored-charge-points/{sponsoredChargePointId}: get: tags: - - Webhooks - summary: Retrieve a single webhook entry by id - description: |- - This endpoint returns a single entry by id. - *Note that we only persist entries for past 24 hours.* - Required scope: `webhooks:read` - operationId: get-webhook-entries_1 + - Sponsored Charge Points + summary: Retrieve a single sponsored charge point + description: "Required scope: `sponsored-charge-points:read`" + operationId: get-sponsored-charge-point parameters: - - name: entryId + - name: sponsoredChargePointId in: path required: true schema: @@ -7157,11 +7016,23 @@ paths: format: int64 responses: "200": - description: Webhook entry with given id + description: Sponsored charge point with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/SponsoredChargePoint" + "404": + description: Entity with the provided id was not found content: application/json: schema: - $ref: '#/components/schemas/WebhookEntry' + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context "401": description: Consumer with provided credentials was not found content: @@ -7172,6 +7043,44 @@ paths: status: UNAUTHORIZED message: Consumer with given `clientId` and `clientSecret` not found errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + delete: + tags: + - Sponsored Charge Points + summary: Delete an existing sponsored charge point + description: "Required scope: `sponsored-charge-points:delete`" + operationId: delete-sponsored-charge-point + parameters: + - name: sponsoredChargePointId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "204": + description: Sponsored Charge Point deleted "404": description: Entity with the provided id was not found content: @@ -7184,6 +7093,26 @@ paths: readableMessage: user friendly message errorCode: RESOURCE_NOT_FOUND context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN "400": description: The request is invalid content: @@ -7196,30 +7125,4187 @@ paths: errorCode: BAD_REQUEST security: - BearerAccessToken: [] -components: - schemas: - AdditionalPricing: - required: - - type - - value - type: object - properties: - type: - allOf: - - $ref: '#/components/schemas/AdditionalPricingType' - - description: Type of the additional pricing. `absolute` means the value - is a price. - example: percentage - value: - allOf: - - $ref: '#/components/schemas/Money' - - description: The value of this additional pricing. Both `absolute` and - `percentage` values here are represented as a money object. - AdditionalPricingType: - type: string - enum: - - absolute - - percentage + patch: + tags: + - Sponsored Charge Points + summary: Update a sponsored charge point + description: "Required scope: `sponsored-charge-points:write`" + operationId: patch-sponsored-charge-point + parameters: + - name: sponsoredChargePointId + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PatchSponsoredChargePoint" + required: true + responses: + "200": + description: Updated sponsored charge point with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/SponsoredChargePoint" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/subscription-purchases: + get: + tags: + - Subscription Purchases + summary: Retrieve a list of subscription purchases + description: "Required scope: `subscriptions:read`" + operationId: get-subscription-purchases + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: subscriptionId + in: query + schema: + required: + - "false" + type: integer + description: Filter subscription purchases by subscription id + format: int64 + nullable: true + example: 1 + - name: includeDeleted + in: query + schema: + required: + - "false" + type: boolean + description: Includes deleted resources in the response + nullable: true + example: true + responses: + "200": + description: List of subscription purchases that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_SubscriptionPurchaseDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/subscription-purchases/{subscriptionPurchaseId}: + get: + tags: + - Subscription Purchases + summary: Retrieve a subscription purchase + description: "Required scope: `subscriptions:read`" + operationId: get-subscription-purchase + parameters: + - name: subscriptionPurchaseId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Subscription purchase with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/SubscriptionPurchase" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/subscriptions: + get: + tags: + - Subscriptions + summary: Retrieve a list of subscriptions + description: "Required scope: `subscriptions:read`" + operationId: get-subscriptions + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: planId + in: query + schema: + required: + - "false" + type: integer + description: Filter subscription by plan + format: int64 + nullable: true + example: 1 + - name: chargePointId + in: query + schema: + required: + - "false" + type: integer + description: "Filter subscriptions by charge point.
*Note*: This field\ + \ is deprecated, use `customerId` instead." + format: int64 + nullable: true + example: 1 + deprecated: true + - name: customerId + in: query + schema: + required: + - "false" + type: integer + description: "Filter subscriptions by customer id (charge point or team\ + \ id).
*Note*: The `customerType` must also be provided when filtering\ + \ by `customerId`." + format: int64 + nullable: true + example: 1 + - name: customerType + in: query + schema: + description: Filter subscriptions by customer type (charge-point or team). + nullable: true + example: team + allOf: + - $ref: "#/components/schemas/SubscriptionCustomerType" + - {} + - name: subscriptionPurchaseId + in: query + schema: + required: + - "false" + type: integer + description: Filter subscriptions by subscription purchase id. + format: int64 + nullable: true + example: 42 + responses: + "200": + description: List of subscriptions that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_SubscriptionDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + post: + tags: + - Subscriptions + summary: Create subscription + description: "Required scope: `subscriptions:write`" + operationId: create-subscription + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateSubscription" + required: true + responses: + "201": + description: The created subscription + content: + application/json: + schema: + $ref: "#/components/schemas/Subscription" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/subscriptions/{subscriptionId}: + get: + tags: + - Subscriptions + summary: Retrieve a subscription + description: "Required scope: `subscriptions:read`" + operationId: get-subscription + parameters: + - name: subscriptionId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Subscription with provided ID + content: + application/json: + schema: + $ref: "#/components/schemas/Subscription" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + delete: + tags: + - Subscriptions + summary: Cancel subscription + description: "Required scope: `subscriptions:delete`" + operationId: delete-subscription + parameters: + - name: subscriptionId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "204": + description: Subscription successfully canceled + content: + application/json: + schema: + $ref: "#/components/schemas/Unit" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/subscriptions/{subscriptionId}/approve: + post: + tags: + - Subscriptions + summary: Approve subscription + description: "Required scope: `subscriptions:write`" + operationId: approve-subscription + parameters: + - name: subscriptionId + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ApproveSubscription" + required: true + responses: + "200": + description: The approved subscription + content: + application/json: + schema: + $ref: "#/components/schemas/Subscription" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/tariff-period-groups: + get: + tags: + - Tariff Period Groups + summary: Retrieve Tariff Period Groups by tariff id + description: "Required scope: `tariff:read`" + operationId: get-period-groups + parameters: + - name: tariffId + in: query + description: Filter to retrieve tariff period groups by tariff id + schema: + type: integer + format: int64 + responses: + "200": + description: Tariff period group with provided tariff id + content: + application/json: + schema: + type: array + items: + $ref: "#/components/schemas/TariffPeriodGroup" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + post: + tags: + - Tariff Period Groups + summary: Create a new Tariff Period Group. + description: "Required scope: `tariffs:write`
**Note: Once you are done\ + \ with creating/updating tariffs and its components you have to call the `create-prices`\ + \ endpoint to create the prices for the tariff.**" + operationId: create-tariff-period-group + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/TariffPeriodGroup_1" + required: true + responses: + "201": + description: New Tariff Period Group + content: + application/json: + schema: + $ref: "#/components/schemas/TariffPeriodGroup" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/tariff-period-groups/{id}: + get: + tags: + - Tariff Period Groups + summary: Retrieve Tariff Period Groups by id + description: "Required scope: `tariff:read`" + operationId: get-period-group + parameters: + - name: id + in: path + description: Filter to retrieve tariff period groups by id + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Tariff period group with provided group id + content: + application/json: + schema: + $ref: "#/components/schemas/TariffPeriodGroup" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + delete: + tags: + - Tariff Period Groups + summary: "Delete an existing Tariff Period Group, and all contained recurring\ + \ periods and prices." + description: "Required scope: `tariffs:delete`
**Note: Once you are done\ + \ with creating/updating tariffs and its components you have to call the `create-prices`\ + \ endpoint to create the prices for the tariff.**" + operationId: delete-tariff-period-group + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "204": + description: Tariff Period Group deleted + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + patch: + tags: + - Tariff Period Groups + summary: Update existing Tariff Period Group. + description: "Required scope: `tariffs:write`
**Note: Once you are done\ + \ with creating/updating tariffs and its components you have to call the `create-prices`\ + \ endpoint to create the prices for the tariff.**" + operationId: update-tariff-period-group + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/TariffPeriodGroup_2" + required: true + responses: + "200": + description: Updated Tariff Period Group + content: + application/json: + schema: + $ref: "#/components/schemas/TariffPeriodGroup" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/tariff-recurring-periods: + get: + tags: + - Tariff Recurring Periods + summary: Retrieve recurring periods. + description: "Required scope: `tariffs:read`" + operationId: get-tariff-recurring-periods + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: tariffId + in: query + required: true + schema: + type: integer + format: int64 + - name: tariffPeriodGroupId + in: query + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Tariff recurring periods with provided tariffId & tariffPeriodGroupId + content: + application/json: + schema: + $ref: "#/components/schemas/Page_TariffRecurringPeriodDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + post: + tags: + - Tariff Recurring Periods + summary: Create new recurring period. + description: "Required scope: `tariffs:write`
**Note: Once you are done\ + \ with creating/updating tariffs and its components you have to call the `create-prices`\ + \ endpoint to create the prices for the tariff.**" + operationId: create-tariff-recurring-periods + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/TariffRecurringPeriodCreateRequestDto" + required: true + responses: + "201": + description: Tariff recurring period that was created + content: + application/json: + schema: + $ref: "#/components/schemas/TariffRecurringPeriod" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/tariff-recurring-periods/{id}: + delete: + tags: + - Tariff Recurring Periods + summary: "Delete an existing Tariff Recurring Period , and all contained prices." + description: "Required scope: `tariffs:delete`
**Note: Once you are done\ + \ with creating/updating tariffs and its components you have to call the `create-prices`\ + \ endpoint to create the prices for the tariff.**" + operationId: delete-tariff-recurring-period + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "204": + description: Tariff Recurring Period deleted + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/tariff-recurring-periods/{periodId}: + get: + tags: + - Tariff Recurring Periods + summary: Retrieve a tariff recurring period. + description: "Required scope: `tariffs:read`" + operationId: get-tariff-recurring-period + parameters: + - name: periodId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Tariff recurring period with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/TariffRecurringPeriod" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + patch: + tags: + - Tariff Recurring Periods + summary: Update existing recurring period. + description: "Required scope: `tariffs:write`
**Note: Once you are done\ + \ with creating/updating tariffs and its components you have to call the `create-prices`\ + \ endpoint to create the prices for the tariff.**" + operationId: update-tariff-recurring-periods + parameters: + - name: periodId + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/TariffRecurringPeriodUpdateRequestDto" + required: true + responses: + "200": + description: Tariff recurring period that was updated + content: + application/json: + schema: + $ref: "#/components/schemas/TariffRecurringPeriod" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/tariffs: + get: + tags: + - Tariff + summary: Retrieve all tariffs. + description: "Required scope: `tariffs:read`" + operationId: get-all-tariffs + parameters: + - name: countryId + in: query + description: Country id of the tariff + schema: + type: integer + format: int64 + - name: countryAreaId + in: query + description: Country area id of the tariff + schema: + type: integer + format: int64 + - name: externalId + in: query + description: External id of the tariff + schema: + type: string + - name: operatorId + in: query + description: Operator id of the tariff (taken from the consumer) + schema: + type: integer + format: int64 + - name: teamId + in: query + description: Team id of the tariff + schema: + type: integer + format: int64 + - name: zip + in: query + description: Zip code of the tariff + schema: + type: string + responses: + "200": + description: All tariffs + content: + application/json: + schema: + type: array + items: + $ref: "#/components/schemas/TariffDto" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + post: + tags: + - Tariff + summary: Create a new Tariff. + description: "Required scope: `tariffs:write`
**Note: Once you are done\ + \ with creating/updating tariffs and its components you have to call the `create-prices`\ + \ endpoint to create the prices for the tariff.**" + operationId: create-tariff + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateTariffRequest" + required: true + responses: + "201": + description: New Tariff + content: + application/json: + schema: + $ref: "#/components/schemas/TariffDto" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/tariffs/{tariffId}: + get: + tags: + - Tariff + summary: Retrieve your tariff and prices. + description: "Required scope: `tariffs:read`" + operationId: get-tariff + parameters: + - name: start + in: query + description: "Filter to retrieve tariffs where `createdAt` >= `start` (ISO8601:\ + \ yyyy-MM-ddTHH:mm:ssZ)" + schema: + type: string + format: date-time + example: 2022-05-22T09:30:03Z + - name: end + in: query + description: "Filter to retrieve charges where `createdAt` <= `end` (ISO8601:\ + \ yyyy-MM-ddTHH:mm:ssZ)" + schema: + type: string + format: date-time + example: 2022-05-22T09:30:03Z + - name: tariffId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Tariff with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/FullTariff" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + put: + tags: + - Tariff + summary: Update an existing Tariff. + description: "Required scope: `tariffs:write`

**Note: Once you are\ + \ done with creating/updating tariffs and its components you have to call\ + \ the `create-prices` endpoint to create the prices for the tariff.**" + operationId: update-tariff + parameters: + - name: tariffId + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/UpdateTariffRequest" + required: true + responses: + "200": + description: Updated Tariff + content: + application/json: + schema: + $ref: "#/components/schemas/TariffDto" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/tariffs/{tariffId}/create-prices: + post: + tags: + - Tariff + summary: Create the prices for a given tariff within a given period of time. + description: "Required scope: `tariffs:write`
**Note: Once you are done\ + \ with creating/updating tariffs and its components you have to call this\ + \ endpoint to create the prices for the tariff.**" + operationId: create-tariff-prices + parameters: + - name: tariffId + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateTariffPricesRequest" + required: true + responses: + "201": + description: Tariff prices created + content: + application/json: + schema: + $ref: "#/components/schemas/FullTariff" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/team-member-profiles: + get: + tags: + - Team Member Profiles + summary: Retrieve a list of team member profiles + description: "Required scope: `team-members:read`" + operationId: getTeamMemberProfiles + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: teamId + in: query + schema: + required: + - "false" + type: integer + description: Filter team member profiles by `teamId` + format: int64 + nullable: true + example: 1 + - name: name + in: query + schema: + required: + - "false" + type: string + description: Filter team member profiles by the specified `name` + nullable: true + example: expired + responses: + "200": + description: List of team member profiles that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_TeamMemberProfileDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + post: + tags: + - Team Member Profiles + summary: Create a team member profile + description: "Create a team member profile so that it can be applied on a team

Required\ + \ scope: `team-members:write`" + operationId: post-team-member-profile + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateTeamMemberProfile" + required: true + responses: + "201": + description: Team member profile created + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMemberProfile" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/team-member-profiles/{id}: + get: + tags: + - Team Member Profiles + summary: Retrieve a team member profile by id + description: "Required scope: `team-members:read`" + operationId: getTeamMemberProfile + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Team member profile with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMemberProfile" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + delete: + tags: + - Team Member Profiles + summary: Delete an existing team member profile + description: "Required scope: `team-members:delete`" + operationId: delete-team-member-profile + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "204": + description: Team member profile deleted + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + patch: + tags: + - Team Member Profiles + summary: Patch a team member profile + description: "Required scope: `team-members:write`" + operationId: updateTeamMemberProfile + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PatchTeamMemberProfile" + required: true + responses: + "200": + description: Updated Team member profile with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMemberProfile" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/team-members: + get: + tags: + - Team Members + summary: Retrieve a list of team members. + description: "Required scope: `team-members:read`" + operationId: getTeamMembers + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: teamId + in: query + schema: + required: + - "false" + type: integer + description: Filter team members by `teamId` + format: int64 + nullable: true + example: 1 + - name: includeDeleted + in: query + schema: + required: + - "false" + type: boolean + description: Includes deleted resources in the response + example: true + default: false + - name: role + in: query + schema: + description: Filter team members by the specified `role` + nullable: true + example: admin + allOf: + - $ref: "#/components/schemas/TeamMemberRole" + - {} + - name: state + in: query + schema: + description: Filter team members by the specified `state` + nullable: true + example: expired + allOf: + - $ref: "#/components/schemas/TeamMemberState_3" + - {} + - name: userId + in: query + schema: + minimum: 0 + exclusiveMinimum: true + required: + - "false" + type: integer + description: Filter team members with specified `userId` + format: int64 + nullable: true + example: 42 + - name: email + in: query + schema: + required: + - "false" + type: string + description: Filter team members with specified `email` + format: email + nullable: true + example: user@acme.com + - name: phone + in: query + schema: + pattern: "^\\+[1-9]\\d{1,14}$" + required: + - "false" + type: string + description: Filter team members with specified `phone` number + nullable: true + example: "+451234567" + - name: partnerExternalTeamId + in: query + schema: + required: + - "false" + type: string + description: "Filter team members by the specified `partnerExternalTeamId`Note:\ + \ partnerExternalTeamId refers to external id on the team level" + nullable: true + example: 1A2B3C4D5E + - name: partnerExternalId + in: query + schema: + required: + - "false" + type: string + description: Filter team members with specified `partnerExternalId` + nullable: true + example: 1A2B3C4D5E + responses: + "200": + description: List of team members that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_TeamMemberDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + post: + tags: + - Team Members + summary: Create (invite) a team member + description: "Create (invite) a user to join a team, invitation can be done\ + \ via `userId`, `email` and/or `phone`. A user that does not exist in yet\ + \ will have a null `userId`.

Required scope: `team-members:write`" + operationId: post-team-member + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateTeamMember" + required: true + responses: + "201": + description: Team member created + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMember" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/team-members/{id}: + get: + tags: + - Team Members + summary: Retrieve a team member. + description: "Required scope: `team-members:read`" + operationId: getTeamMember + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Team member with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMember" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + patch: + tags: + - Team Members + summary: Patch a team member. + description: "Required scope: `team-members:write`" + operationId: patchTeamMember + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PatchTeamMember" + required: true + responses: + "200": + description: Updated Team member with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMember" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/team-members/{id}/accept: + post: + tags: + - Team Members + summary: Approve a team member who requested to join a team + description: "Required scope: `team-members:write`" + operationId: acceptTeamMemberJoinRequest + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Team member with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMember" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/team-members/{id}/resend-invite: + post: + tags: + - Team Members + summary: Resend an invite to a team member and reset expiry date. + description: "Required scope: `team-members:write`" + operationId: resendTeamMemberInvite + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Team member with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMember" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/team-members/{teamMemberId}: + delete: + tags: + - Team Members + summary: Delete an existing team member + description: "Required scope: `team-members:delete`" + operationId: delete-team-member + parameters: + - name: teamMemberId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "204": + description: Team member deleted + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/teams: + get: + tags: + - Teams + summary: Retrieve a list of teams + description: "Required scope: `teams:read`
Organization authorization:\ + \ `supported`" + operationId: get-teams + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + responses: + "200": + description: List of teams that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_TeamDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + post: + tags: + - Teams + summary: Create a team + description: "Required scope: `teams:write`
Organization authorization:\ + \ `supported`" + operationId: post-team + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateTeamDto" + required: true + responses: + "201": + description: Team created + content: + application/json: + schema: + $ref: "#/components/schemas/Team" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/teams/{id}: + get: + tags: + - Teams + summary: Retrieve a team + description: "Required scope: `teams:read`
Organization authorization:\ + \ `supported`" + operationId: get-team + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Team with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/Team" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/teams/{id}/freeze: + post: + tags: + - Teams + summary: Freeze a team + description: "Required scope: `teams:write`
Organization authorization:\ + \ `supported`" + operationId: freeze-team + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/UpdateTeamStateDto" + required: true + responses: + "200": + description: Team with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/Team" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/teams/{id}/unfreeze: + post: + tags: + - Teams + summary: Unfreeze a team + description: "Required scope: `teams:write`
Organization authorization:\ + \ `supported`" + operationId: unfreeze-team + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Team with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/Team" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/teams/{teamId}: + delete: + tags: + - Teams + summary: Delete an existing team + description: "Required scope: `teams:delete`
Organization authorization:\ + \ `supported`" + operationId: delete-team + parameters: + - name: teamId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "204": + description: Team deleted + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + patch: + tags: + - Teams + summary: Patch an existing team + description: "Required scope: `teams:write`
Organization authorization:\ + \ `supported`" + operationId: patch-team + parameters: + - name: teamId + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PatchTeam" + required: true + responses: + "200": + description: Team updated + content: + application/json: + schema: + $ref: "#/components/schemas/Team" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/users: + get: + tags: + - Users + summary: Retrieve users + description: "Required scope: `users:read`" + operationId: get-users + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: email + in: query + description: filter user by email + schema: + type: string + format: email + example: user@example.com + - name: phone + in: query + description: filter user by phone + schema: + type: string + format: phone + example: "+4529930022" + - name: includeDeleted + in: query + description: "Set to 'true' to include deleted users, 'false' otherwise" + schema: + type: boolean + default: false + example: false + responses: + "200": + description: List of users that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_UserDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/users/{userId}: + get: + tags: + - Users + summary: Retrieve a user + description: "Required scope: `users:read`" + operationId: get-user + parameters: + - name: userId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: user with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/User" + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/wallet-transactions: + get: + tags: + - Wallet Transactions + summary: Retrieve your wallet transactions + description: "Required scope: `wallet-transactions:read`
Organization authorization:\ + \ `supported`" + operationId: get-wallet-transactions + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: operatorId + in: query + schema: + type: integer + description: "Filter to retrieve transactions for a given operator.
*Note*:\ + \ When not provided the default operator will be used for the given consumer,\ + \ if the default operator cannot be assigned the request will be rejected" + format: int32 + nullable: true + example: 1 + - name: teamId + in: query + schema: + type: integer + description: "Filter to retrieve transactions for a given team.
*Note*:\ + \ When not provided the transactions for the operator will be returned\ + \ instead" + format: int32 + nullable: true + example: 1 + - name: fromDate + in: query + schema: + pattern: "^(\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2})Z$" + type: string + description: "Filter to retrieve transactions where `createdAt` >= `fromDate`\ + \ (ISO8601: yyyy-MM-ddTHH:mm:ssZ)" + format: date-time + nullable: true + example: 2022-05-22T09:30:03Z + - name: toDate + in: query + schema: + pattern: "^(\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2})Z$" + type: string + description: "Filter to retrieve transactions where `createdAt` <= `toDate`\ + \ (ISO8601: yyyy-MM-ddTHH:mm:ssZ)" + format: date-time + nullable: true + example: 2022-05-22T09:30:03Z + - name: referenceId + in: query + schema: + type: string + description: Filter to retrieve transactions by the matching referenceId + nullable: true + example: "1" + - name: referenceType + in: query + schema: + description: Filter to retrieve transactions by the matching referenceType + nullable: true + example: CHARGE + allOf: + - $ref: "#/components/schemas/WalletTransactionReferenceType" + - type: string + - name: state + in: query + schema: + description: Filter to retrieve transactions by the matching state + nullable: true + example: complete + allOf: + - $ref: "#/components/schemas/WalletTransactionState" + - type: string + - name: group + in: query + schema: + description: Filter to retrieve transactions by the matching group + nullable: true + example: deposit + allOf: + - $ref: "#/components/schemas/WalletTransactionGroup" + - type: string + - name: partnerExternalId + in: query + schema: + required: + - "false" + type: string + description: "**Note: This has been deprecated and won't do anything moving\ + \ forward.**Filter transactions by partnerExternalId, to filter only resources\ + \ without `partnerExternalId` *use* `partnerExternalId=\"\"`" + nullable: true + example: "1" + responses: + "200": + description: List of wallet transactions that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_WalletTransactionDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/wallet-transactions/invoices/{invoiceId}: + get: + tags: + - Wallet Transactions + summary: Retrieves wallet transactions for an invoice + description: "Required scope: `wallet-transactions:read
Organization authorization:\ + \ `supported`" + operationId: get-wallet-transactions_1 + parameters: + - name: invoiceId + in: path + required: true + schema: + type: integer + format: int64 + - name: pageable + in: query + required: true + schema: + $ref: "#/components/schemas/Pageable" + responses: + "200": + description: Transactions by invoice successfully retrieved + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_WalletTransactionDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/wallet-transactions/operator-adjustment-transaction: + post: + tags: + - Wallet Transactions + summary: Post an operator adjustment transaction + description: "This API endpoint is for operator to create an adjustment transaction\ + \ to their teams. Required scope: `wallet-transaction:write`" + operationId: post-operator-adjustment-transaction + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/OperatorAdjustmentTransaction" + required: true + responses: + "201": + description: Transaction created + content: + application/json: + schema: + $ref: "#/components/schemas/WalletTransaction" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/wallet-transactions/{transactionId}: + get: + tags: + - Wallet Transactions + summary: Retrieve a single wallet transaction + description: "Required scope: `wallet-transactions:read`
Organization authorization:\ + \ `supported`" + operationId: get-wallet-transaction + parameters: + - name: transactionId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Wallet transaction with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/WalletTransaction" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + patch: + tags: + - Wallet Transactions + summary: Patch an existing transaction + description: "**Note: This has been deprecated and won't do anything.** Required\ + \ scope: `transaction:write`" + operationId: patch-transaction + parameters: + - name: transactionId + in: path + required: true + schema: + type: integer + format: int64 + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PatchWalletTransaction" + required: true + responses: + "200": + description: Transaction updated + content: + application/json: + schema: + $ref: "#/components/schemas/WalletTransaction" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + deprecated: true + security: + - BearerAccessToken: [] + /api/v1/wallets: + get: + tags: + - Wallets + summary: Retrieve your wallets. + description: "Required scope: `wallet-transactions:read`" + operationId: get-wallets + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: teamId + in: query + schema: + type: integer + description: "Filter to retrieve wallet for a given team. *Note*: You need\ + \ to either provide `teamId` or `operatorId`" + format: int32 + nullable: true + example: 1 + - name: operatorId + in: query + schema: + type: integer + description: "Filter to retrieve wallet for a given operator. *Note*: You\ + \ need to either provide `teamId` or `operatorId`" + format: int32 + nullable: true + example: 1 + responses: + "200": + description: List of wallets that match the criteria + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_WalletDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/wallets/{walletId}: + get: + tags: + - Wallets + summary: Retrieve a single wallet. + description: "Required scope: `wallet-transactions:read`" + operationId: get-wallet + parameters: + - name: walletId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Wallet with provided id + content: + application/json: + schema: + $ref: "#/components/schemas/Wallet" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/webhooks/config: + get: + tags: + - Webhooks + summary: Get your webhook config + description: "Required scope: `manage-webhooks:read`" + operationId: get-webhook-config + responses: + "200": + description: Your Webhook config. + content: + application/json: + schema: + $ref: "#/components/schemas/WebhookConfig" + "404": + description: Webhook config not found. + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + put: + tags: + - Webhooks + summary: Update your webhook config + description: "Required scope: `manage-webhooks:write`" + operationId: update-webhook-config + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/WebhookConfig" + required: true + responses: + "200": + description: Webhook config successfully updated. + content: + application/json: + schema: + $ref: "#/components/schemas/WebhookConfig" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + delete: + tags: + - Webhooks + summary: Delete webhook config + description: "Required scope: `manage-webhooks:delete`" + operationId: delete-webhook-config + responses: + "204": + description: Successfully deleted webhook configuration + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/webhooks/entries: + get: + tags: + - Webhooks + summary: Retrieve webhook entries + description: "This endpoint can help you debug pending/failed webhook entries.\ + \ Required scope: `webhooks:read`" + operationId: get-webhook-entries + parameters: + - name: page + in: query + description: page number to retrieve (starts with 0) + schema: + type: integer + format: int32 + default: 0 + example: 1 + - name: perPage + in: query + description: "number of items per page (between 1 and 100, default 10)" + schema: + type: integer + format: int32 + default: 10 + example: 10 + - name: status + in: query + schema: + type: string + description: Filter to retrieve entries by `status` + nullable: true + example: failed + enum: + - pending + - completed + - failed + responses: + "200": + description: List of webhook entries for your consumer in the past 24 hours + content: + application/json: + schema: + $ref: "#/components/schemas/MontaPage_WebhookEntryDto_" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] + /api/v1/webhooks/entries/{entryId}: + get: + tags: + - Webhooks + summary: Retrieve a single webhook entry by id + description: |- + This endpoint returns a single entry by id. + *Note that we only persist entries for past 24 hours.* + Required scope: `webhooks:read` + operationId: get-webhook-entries_1 + parameters: + - name: entryId + in: path + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: Webhook entry with given id + content: + application/json: + schema: + $ref: "#/components/schemas/WebhookEntry" + "404": + description: Entity with the provided id was not found + content: + application/json: + schema: + type: object + example: + status: NOT_FOUND + message: Requested entity/entity provided in body was not found + readableMessage: user friendly message + errorCode: RESOURCE_NOT_FOUND + context: context + "401": + description: Consumer with provided credentials was not found + content: + application/json: + schema: + type: object + example: + status: UNAUTHORIZED + message: Consumer with given `clientId` and `clientSecret` not found + errorCode: CONSUMER_NOT_FOUND + "403": + description: Operator doesn't have access to resource + content: + application/json: + schema: + type: object + example: + status: FORBIDDEN + message: Operator doesn't have access to resource + errorCode: ACCESS_FORBIDDEN + "400": + description: The request is invalid + content: + application/json: + schema: + type: object + example: + status: BAD_REQUEST + message: Invalid request + errorCode: BAD_REQUEST + security: + - BearerAccessToken: [] +components: + schemas: + AdditionalPricing: + required: + - type + - value + type: object + properties: + type: + description: Type of the additional pricing. `absolute` means the value + is a price. + example: percentage + allOf: + - $ref: "#/components/schemas/AdditionalPricingType" + - {} + value: + description: The value of this additional pricing. Both `absolute` and `percentage` + values here are represented as a money object. + allOf: + - $ref: "#/components/schemas/Money" + - {} + title: + required: + - "false" + type: string + description: A title for this additional pricing. + nullable: true + AdditionalPricingType: + type: string + enum: + - absolute + - percentage Address: required: - address1 @@ -7236,7 +11322,7 @@ components: type: string description: Second line of address nullable: true - example: København + example: København address3: type: string description: Third line of address @@ -7354,7 +11440,7 @@ components: description: The list of prices and tariffs relevant for this breakdown entry items: - $ref: '#/components/schemas/Component' + $ref: "#/components/schemas/Component" BreakdownSummary: required: - totalAdjustments @@ -7401,6 +11487,14 @@ components: description: Total price for the given charge format: int64 example: 2220 + totalDiscount: + required: + - "false" + type: integer + description: Total discount applied for the given charge + format: int64 + nullable: true + example: 2220 Charge: required: - costBreakdown @@ -7420,30 +11514,34 @@ components: format: int64 example: 1 user: + description: User that performed the charge allOf: - - $ref: '#/components/schemas/PublicUser' - - description: User that performed the charge + - $ref: "#/components/schemas/PublicUser_3" + - {} teamMember: + description: "Team that performed the charge, if part of the charge points'\ + \ team" nullable: true allOf: - - $ref: '#/components/schemas/SimpleTeamMemberDto' - - description: "Team that performed the charge, if part of the charge points'\ - \ team" + - $ref: "#/components/schemas/SimpleTeamMemberDto" + - {} type: + description: Type of the charge + example: "1" allOf: - - $ref: '#/components/schemas/ChargeType' - - description: Type of the charge - example: "1" + - $ref: "#/components/schemas/ChargeType" + - {} chargePointId: type: integer description: Id of the charge point related to this charge format: int64 example: 21 publicChargePoint: + description: The public information about the charge point related to this + charge allOf: - - $ref: '#/components/schemas/PublicChargePoint' - - description: The public information about the charge point related to - this charge + - $ref: "#/components/schemas/PublicChargePoint" + - {} sponsoredChargePointId: required: - "false" @@ -7532,11 +11630,11 @@ components: nullable: true example: 2022-05-12T16:56:45.99Z state: + description: State of the charge + example: charging allOf: - - $ref: '#/components/schemas/ChargeStateDto' + - $ref: "#/components/schemas/ChargeStateDto" - type: string - description: State of the charge - example: charging startSource: type: string description: "Indicates the starting source for this charge, e.g app-ios,\ @@ -7560,7 +11658,7 @@ components: type: array description: List of consumed Kwh split by hour items: - $ref: '#/components/schemas/KwhPerHour' + $ref: "#/components/schemas/KwhPerHour" costBreakdown: type: array description: "Detailed breakdown of the costs by hour

**Note**:\ @@ -7568,7 +11666,7 @@ components: \ endpoint instead" deprecated: true items: - $ref: '#/components/schemas/ChargeCost' + $ref: "#/components/schemas/ChargeCost" x-sunset: 2024-04-01 priceBreakdown: type: array @@ -7577,7 +11675,7 @@ components: \ endpoint instead" deprecated: true items: - $ref: '#/components/schemas/ChargePrice' + $ref: "#/components/schemas/ChargePrice" x-sunset: 2024-04-01 startMeterKwh: type: number @@ -7648,36 +11746,42 @@ components: nullable: true example: Lorem Ipsum currency: + description: Currency used for payment. nullable: true allOf: - - $ref: '#/components/schemas/Currency' - - description: Currency used for payment. + - $ref: "#/components/schemas/Currency_11" + - {} payingTeam: + description: Team who paid for this charge nullable: true allOf: - - $ref: '#/components/schemas/PayingTeam' - - description: Team who paid for this charge + - $ref: "#/components/schemas/PayingTeam" + - {} sponsorTeam: + description: Team who sponsored this charge nullable: true allOf: - - $ref: '#/components/schemas/SponsorTeam' - - description: Team who sponsored this charge + - $ref: "#/components/schemas/SponsorTeam" + - {} operator: + description: Operator this of this charge nullable: true allOf: - - $ref: '#/components/schemas/Operator' - - description: Operator this of this charge + - $ref: "#/components/schemas/Operator" + - {} chargeAuth: + description: The object used to authenticate a charge nullable: true allOf: - - $ref: '#/components/schemas/ChargeAuthentication' - - description: The object used to authenticate a charge + - $ref: "#/components/schemas/ChargeAuthentication" + - {} soc: + description: Information about the state of charge if available nullable: true + example: "42" allOf: - - $ref: '#/components/schemas/StateOfCharge' - - description: Information about the state of charge if available - example: "42" + - $ref: "#/components/schemas/StateOfCharge" + - {} socLimit: type: number description: Configured SoC limit for this charge @@ -7685,11 +11789,12 @@ components: nullable: true example: 80 genericPaymentSession: + description: "Generic payment session for this charge. If provided, the\ + \ charge was paid with this payment session." nullable: true allOf: - - $ref: '#/components/schemas/GenericPaymentSession' - - description: "Generic payment session for this charge. If provided, the\ - \ charge was paid with this payment session." + - $ref: "#/components/schemas/GenericPaymentSession" + - {} partnerExternalId: type: string description: "External Id of this entity, managed by you. **We recommend\ @@ -7762,10 +11867,11 @@ components: nullable: true example: Monta Team Key operator: + description: Operator of this charge auth token nullable: true allOf: - - $ref: '#/components/schemas/Operator' - - description: Operator of this charge auth token + - $ref: "#/components/schemas/Operator" + - {} montaNetwork: type: boolean description: If the charge auth token is active in the Monta network @@ -7848,15 +11954,17 @@ components: format: int64 example: 10001 priceBreakdown: + description: "The price breakdown, Includes information necessary to understand\ + \ the composition of the final charge price" allOf: - - $ref: '#/components/schemas/DetailedBreakdown' - - description: "The price breakdown, Includes information necessary to understand\ - \ the composition of the final charge price" + - $ref: "#/components/schemas/DetailedBreakdown" + - {} costBreakdown: + description: The cost breakdown is similar to the price breakdown but focuses + on the costs incurred for the given charge allOf: - - $ref: '#/components/schemas/DetailedBreakdown' - - description: The cost breakdown is similar to the price breakdown but - focuses on the costs incurred for the given charge + - $ref: "#/components/schemas/DetailedBreakdown" + - {} ChargeCost: required: - time @@ -7888,9 +11996,10 @@ components: format: double example: 13.77 type: + description: The type of this metadata allOf: - - $ref: '#/components/schemas/MetadataTypeDto' - - description: The type of this metadata + - $ref: "#/components/schemas/MetadataTypeDto" + - {} ChargePoint: required: - connectors @@ -7930,10 +12039,11 @@ components: nullable: true example: 42 operator: + description: Operator of this charge point nullable: true allOf: - - $ref: '#/components/schemas/Operator' - - description: Operator of this charge point + - $ref: "#/components/schemas/Operator" + - {} createdAt: type: string description: Creation date of this charge point @@ -8009,26 +12119,28 @@ components: nullable: true example: "Installer note: XYZ" state: + description: State of the charge point nullable: true + example: available allOf: - - $ref: '#/components/schemas/ChargePointState' + - $ref: "#/components/schemas/ChargePointState" - type: string - description: State of the charge point - example: available location: + description: Location information for this charge point allOf: - - $ref: '#/components/schemas/Location' - - description: Location information for this charge point + - $ref: "#/components/schemas/Location" + - {} connectors: type: array description: "List of supported connector types at this charge point (e.g.\ \ type-2, ccs, ...)" items: - $ref: '#/components/schemas/ChargePointConnector' + $ref: "#/components/schemas/ChargePointConnector" deeplinks: + description: Deeplinks to open charge screen in Monta app or web. allOf: - - $ref: '#/components/schemas/ChargePointDeeplinks' - - description: Deeplinks to open charge screen in Monta app or web. + - $ref: "#/components/schemas/ChargePointDeeplinks" + - {} lastMeterReadingKwh: type: number description: Last meter reading (KWH) for this charge point @@ -8061,12 +12173,13 @@ components: nullable: true example: v1 integrationType: + description: "Indicates what kind of integration this charge point is using\ + \ (e.g oicp, ocpi, Note: null meaning not integrated)" nullable: true + example: oicp allOf: - - $ref: '#/components/schemas/ChargePointIntegrationType' - - description: "Indicates what kind of integration this charge point is\ - \ using (e.g oicp, ocpi, Note: null meaning not integrated)" - example: oicp + - $ref: "#/components/schemas/ChargePointIntegrationType" + - {} evseId: type: string description: The EVSE id for this charge point @@ -8110,6 +12223,29 @@ components: reserved for
`null` indicates that reservation is not supported. format: int32 nullable: true + example: null + simCard: + description: SIM card data for the given charge point + nullable: true + allOf: + - $ref: "#/components/schemas/SimCard" + - {} + roaming: + type: boolean + description: Indicates whether roaming is enabled for this charge point + example: true + lastConnectedAt: + type: string + description: The last date/time this charge point was reported as connected + format: date-time + nullable: true + example: 2023-01-18T00:00:00Z + disconnectedAt: + type: string + description: The date/time this charge point was reported as disconnected + format: date-time + nullable: true + example: 2023-01-01T00:00:00Z ChargePointBrand: required: - identifier @@ -8190,10 +12326,11 @@ components: format: int64 example: 1 state: + description: The current state of the charge point integration + example: connected allOf: - - $ref: '#/components/schemas/ChargePointIntegrationStateDto' - - description: The current state of the charge point integration - example: connected + - $ref: "#/components/schemas/ChargePointIntegrationStateDto" + - {} serialNumber: type: string description: The serial number of this charge point integration @@ -8209,9 +12346,10 @@ components: nullable: true example: 1 chargePoint: + description: The charge point associated to this integration allOf: - - $ref: '#/components/schemas/ChargePoint' - - description: The charge point associated to this integration + - $ref: "#/components/schemas/ChargePoint" + - {} activeAt: type: string description: The Date this charge point integration was set to active @@ -8246,6 +12384,11 @@ components: - unknown ChargePointIntegrationType: type: string + description: "definitions: \n* `oicp` - Indicates the current integration is\ + \ OICP. \n* `ocpi` - Indicates the current integration is OCPI. \n* `ocpp`\ + \ - Indicates the current integration is OCPP. \n* `other` - Fallback value,\ + \ Indicates a new type was added but is not mapped/unknown on this API yet.\ + \ \n" enum: - oicp - ocpi @@ -8274,15 +12417,16 @@ components: \ name - Model name)" example: SecuriCharge Dual brand: + description: The brand of the charge point model allOf: - - $ref: '#/components/schemas/ChargePointModelDto.ChargePointBrandDto' - - description: The brand of the charge point model + - $ref: "#/components/schemas/ChargePointModelDto.ChargePointBrandDto" + - {} features: type: array description: "The supported features by this charge point model, only supported\ \ features will be included" items: - $ref: '#/components/schemas/ChargePointModelFeature' + $ref: "#/components/schemas/ChargePointModelFeature" createdAt: type: string description: Creation date of this charge point model @@ -8332,6 +12476,22 @@ components: type: boolean description: The current status of the feature example: true + ChargePointOcppLog: + required: + - message + - timestamp + type: object + properties: + timestamp: + type: string + description: Timestamp of the OCPP log + format: date-time + example: 2022-05-12T15:56:45.99Z + message: + type: string + description: "Message content of the OCPP log, can be a string or an array\ + \ of mixed types" + example: Charge point connected ChargePointState: type: string description: "Various types of Charge Point states. Definitions: \n\n* `available`\ @@ -8345,9 +12505,7 @@ components: \ in use and scheduled. \n* `error` - The charge point is in an error state.\ \ \n* `disconnected` - The charge point is disconnected from Monta. \n* `passive`\ \ - The charge point is in a passive state, charging can only be controlled\ - \ locally. \n* `maintenance` - The charge point is in maintenance mode. \n\ - * `other` - Fallback value, Indicates a new type was added but is not mapped/unknown\ - \ on this API yet. \n" + \ locally. \n* `maintenance` - The charge point is in maintenance mode. \n" enum: - available - busy @@ -8362,6 +12520,78 @@ components: - passive - maintenance - other + ChargePointStatisticsDto: + required: + - fromDate + - sessionSuccessRate + - toDate + - totalEnergyConsumed + - totalSessions + type: object + properties: + fromDate: + required: + - "true" + type: string + description: Start date of the statistics period + format: date-time + example: 2024-03-20T00:00:00Z + toDate: + required: + - "true" + type: string + description: End date of the statistics period + format: date-time + example: 2024-03-30T00:00:00Z + totalEnergyConsumed: + required: + - "true" + type: number + description: Total energy consumed during the period (in kWh) + example: 500.5 + totalSessions: + required: + - "true" + type: integer + description: Total number of charging sessions during the period + format: int32 + example: 150 + sessionSuccessRate: + required: + - "true" + type: number + description: Success rate of charging sessions during the period (as a percentage) + format: double + example: 95 + systemUptimePercentage: + required: + - "false" + type: number + description: Percentage of uptime for the system during the period + format: double + nullable: true + example: 99.9 + states: + required: + - "false" + type: array + description: Detailed state for the period + items: + $ref: "#/components/schemas/States" + days: + required: + - "false" + type: array + description: Daily statistics for the period + items: + $ref: "#/components/schemas/TimePeriod" + months: + required: + - "false" + type: array + description: Monthly statistics for the period + items: + $ref: "#/components/schemas/TimePeriod" ChargePrice: required: - time @@ -8411,10 +12641,11 @@ components: type: object properties: type: + description: The type of charge insight + example: completed-charges-insights allOf: - - $ref: '#/components/schemas/ChargesInsightTypeDto' - - description: The type of charge insight - example: completed-charges-insights + - $ref: "#/components/schemas/ChargesInsightTypeDto" + - {} fromDate: type: string description: "Indicates the starting period (`fromDate`) used calculate\ @@ -8434,20 +12665,127 @@ components: description: The title for for this charge insight example: Completed charge sessions insights operator: + description: The operator to which this charge insight belongs to allOf: - - $ref: '#/components/schemas/Operator' - - description: The operator to which this charge insight belongs to + - $ref: "#/components/schemas/Operator" + - {} currency: + description: The currency applicable for this charge insight allOf: - - $ref: '#/components/schemas/Currency' - - description: The currency applicable for this charge insight + - $ref: "#/components/schemas/Currency_5" + - {} insights: required: - "true" type: array - description: The compilation of insights entries composing this charge insight + description: The compilation of insights entries composing this charge insight + items: + $ref: "#/components/schemas/ChargesInsightEntry" + ChargesInsightByChargeAuthTokenReportDto: + required: + - consumptions + - identifier + - type + type: object + properties: + id: + type: integer + description: The id of the charge auth token + format: int64 + example: 1 + identifier: + type: string + description: "The identifier of the charge auth token, Note: without prefix\ + \ e.g `VID:`" + example: 38C58DB85F4 + type: + type: string + description: The method type used for this charge auth token + example: vehicleId + enum: + - vehicleId + - rfid + consumptions: + required: + - "true" + type: array + description: Charge consumptions grouped by `chargeType` items: - $ref: '#/components/schemas/ChargesInsightEntry' + $ref: "#/components/schemas/ChargesInsightByChargeAuthTokenReportDto.Consumption" + ChargesInsightByChargeAuthTokenReportDto.Consumption: + required: + - chargeType + - totalGrossPrice + - totalKwh + - totalNetPrice + - totalSessions + - totalVat + type: object + properties: + chargeType: + required: + - "true" + type: string + description: "Defines the type of charge, ie. if it was a sponsored or public\ + \ charge. \n\ndefinitions: \n* `sponsored` - Charges that have been sponsored.\ + \ \n* `team-operator` - Charges that belong to Charge Points of the same\ + \ operator as paying team operator. \n* `public` - Any charge that was\ + \ paid for by this team that does not match the other cases. \n\nNote\ + \ that more chargeTypes might be added in the future. Make sure to handle\ + \ this gracefully." + totalSessions: + required: + - "true" + type: integer + description: Number of charging sessions + format: int64 + totalKwh: + required: + - "true" + type: number + description: Sum of all Kwh consumed + format: double + totalNetPrice: + required: + - "true" + type: number + description: Sum of all charge net prices + format: double + totalVat: + required: + - "true" + type: number + description: Sum of all charge vat amounts + format: double + totalGrossPrice: + required: + - "true" + type: number + description: Sum of all charge gross prices + format: double + memberCostGroupId: + required: + - "false" + type: integer + description: "The ID of the Member Cost Group applied to this charges, or\ + \ Null if none" + format: int64 + nullable: true + memberCostGroupName: + required: + - "false" + type: string + description: "The name of the Member Cost Group applied to this charges,\ + \ or Null if none" + nullable: true + memberCostGroupPrice: + required: + - "false" + type: number + description: "Sum of all charge costs in the Member Cost Group currency,\ + \ or Null if none" + format: double + nullable: true ChargesInsightChargerReport: required: - chargePointId @@ -8481,7 +12819,7 @@ components: type: array description: Charge consumptions items: - $ref: '#/components/schemas/ChargesInsightChargerReportDto.Consumption' + $ref: "#/components/schemas/ChargesInsightChargerReportDto.Consumption" ChargesInsightChargerReportDto.Consumption: required: - totalKwh @@ -8500,6 +12838,174 @@ components: type: number description: Sum of all Kwh consumed format: double + ChargesInsightDriverMemberCostsReport: + required: + - consumptions + - teamId + - teamMemberId + - userId + type: object + properties: + teamId: + required: + - "true" + type: integer + description: Team ID used for this report + format: int64 + teamMemberId: + required: + - "true" + type: integer + description: Team Member ID of the Driver + format: int64 + userId: + required: + - "true" + type: integer + description: User ID of the Driver + format: int64 + consumptions: + required: + - "true" + type: array + description: Charge consumptions grouped by `chargeType` + items: + $ref: "#/components/schemas/ChargesInsightDriverMemberCostsReportDto.Consumption" + ChargesInsightDriverMemberCostsReportDto.Consumption: + required: + - chargeType + - countryBreakdown + - totalGrossPrice + - totalKwh + - totalNetPrice + - totalSessions + - totalVat + type: object + properties: + chargeType: + required: + - "true" + type: string + description: "Defines the type of charge, ie. if it was a sponsored or public\ + \ charge. \n\ndefinitions: \n* `sponsored` - Charges that have been sponsored.\ + \ \n* `team-operator` - Charges that belong to Charge Points of the same\ + \ operator as paying team operator. \n* `public` - Any charge that was\ + \ paid for by this team that does not match the other cases. \n\nNote\ + \ that more chargeTypes might be added in the future. Make sure to handle\ + \ this gracefully." + totalSessions: + required: + - "true" + type: integer + description: Number of charging sessions + format: int64 + totalKwh: + required: + - "true" + type: number + description: Sum of all Kwh consumed + format: double + totalNetPrice: + required: + - "true" + type: number + description: Sum of all charge net prices + format: double + totalVat: + required: + - "true" + type: number + description: Sum of all charge vat amounts + format: double + totalGrossPrice: + required: + - "true" + type: number + description: Sum of all charge gross prices + format: double + memberCostGroupId: + required: + - "false" + type: integer + description: "The ID of the Member Cost Group applied to this charges, or\ + \ Null if none" + format: int64 + nullable: true + memberCostGroupName: + required: + - "false" + type: string + description: "The name of the Member Cost Group applied to this charges,\ + \ or Null if none" + nullable: true + memberCostGroupPrice: + required: + - "false" + type: number + description: "Sum of all charge costs in the Member Cost Group currency,\ + \ or Null if none" + format: double + nullable: true + countryBreakdown: + required: + - "true" + type: array + description: Breakdown of the charges by country + items: + $ref: "#/components/schemas/ChargesInsightDriverMemberCostsReportDto.Consumption.CountryBreakdown" + ChargesInsightDriverMemberCostsReportDto.Consumption.CountryBreakdown: + required: + - countryCode + - totalGrossPrice + - totalKwh + - totalNetPrice + - totalSessions + - totalVat + type: object + properties: + countryCode: + required: + - "true" + type: string + description: Two letter Country Code + totalSessions: + required: + - "true" + type: integer + description: Number of charging sessions + format: int64 + totalKwh: + required: + - "true" + type: number + description: Sum of all Kwh consumed + format: double + totalNetPrice: + required: + - "true" + type: number + description: Sum of all charge net prices + format: double + totalVat: + required: + - "true" + type: number + description: Sum of all charge vat amounts + format: double + totalGrossPrice: + required: + - "true" + type: number + description: Sum of all charge gross prices + format: double + memberCostGroupPrice: + required: + - "false" + type: number + description: "Sum of all charge costs in the Member Cost Group currency,\ + \ or Null if none" + format: double + nullable: true ChargesInsightDriverReport: required: - consumptions @@ -8532,7 +13038,7 @@ components: type: array description: Charge consumptions grouped by `chargeType` items: - $ref: '#/components/schemas/ChargesInsightDriverReportDto.Consumption' + $ref: "#/components/schemas/ChargesInsightDriverReportDto.Consumption" ChargesInsightDriverReportDto.Consumption: required: - chargeType @@ -8591,15 +13097,17 @@ components: type: object properties: type: + description: The type for this insight entry + example: completed-sponsored-charges-insights allOf: - - $ref: '#/components/schemas/ChargesInsightEntryTypeDto' - - description: The type for this insight entry - example: completed-sponsored-charges-insights + - $ref: "#/components/schemas/ChargesInsightEntryTypeDto" + - {} summary: + description: "The summary for this insight entry, The summary contains the\ + \ compiled statistics for the entry" allOf: - - $ref: '#/components/schemas/ChargesInsightSummary' - - description: "The summary for this insight entry, The summary contains\ - \ the compiled statistics for the entry" + - $ref: "#/components/schemas/ChargesInsightSummary" + - {} ChargesInsightEntryTypeDto: type: string description: Enumerate the various types of charge insights @@ -8659,10 +13167,11 @@ components: type: object properties: type: + description: The type of price/fee for this component + example: tariff allOf: - - $ref: '#/components/schemas/ComponentTypeDto' - - description: The type of price/fee for this component - example: tariff + - $ref: "#/components/schemas/ComponentTypeDto" + - {} price: required: - "true" @@ -8683,40 +13192,42 @@ components: description: Indicates this component is master a master pricing example: true tag: + description: The tag for this component nullable: true allOf: - - $ref: '#/components/schemas/PriceGroupTag' - - description: The tag for this component + - $ref: "#/components/schemas/PriceGroupTag" + - {} metadata: + description: "Additional information (metadata) for this component, e.g\ + \ tariffId, kwh and others" nullable: true allOf: - - $ref: '#/components/schemas/ComponentMetadataDto' - - description: "Additional information (metadata) for this component, e.g\ - \ tariffId, kwh and others" + - $ref: "#/components/schemas/ComponentMetadataDto" + - {} ComponentMetadataDto: required: - type type: object properties: type: - $ref: '#/components/schemas/ComponentMetadataTypeDto' + $ref: "#/components/schemas/ComponentMetadataTypeDto" discriminator: propertyName: type mapping: - spot-price-additional-price-metadata: '#/components/schemas/SpotPriceAdditionalPercentageComponentMetadata' - spot-price-metadata: '#/components/schemas/SpotPriceComponentMetadata' - tariff-metadata: '#/components/schemas/TariffComponentMetadata' - default-metadata: '#/components/schemas/DefaultComponentMetadata' - duration-fee-metadata: '#/components/schemas/DurationFeeComponentMetadata' - idle-fee-metadata: '#/components/schemas/IdleFeeComponentMetadata' + spot-price-additional-price-metadata: "#/components/schemas/SpotPriceAdditionalPercentageComponentMetadata" + spot-price-metadata: "#/components/schemas/SpotPriceComponentMetadata" + tariff-metadata: "#/components/schemas/TariffComponentMetadata" + default-metadata: "#/components/schemas/DefaultComponentMetadata" + duration-fee-metadata: "#/components/schemas/DurationFeeComponentMetadata" + idle-fee-metadata: "#/components/schemas/IdleFeeComponentMetadata" oneOf: - - $ref: '#/components/schemas/SpotPriceComponentMetadata' - - $ref: '#/components/schemas/SpotPriceAdditionalPriceComponentMetadata' - - $ref: '#/components/schemas/SpotPriceAdditionalPercentageComponentMetadata' - - $ref: '#/components/schemas/DurationFeeComponentMetadata' - - $ref: '#/components/schemas/IdleFeeComponentMetadata' - - $ref: '#/components/schemas/TariffComponentMetadata' - - $ref: '#/components/schemas/DefaultComponentMetadata' + - $ref: "#/components/schemas/SpotPriceComponentMetadata" + - $ref: "#/components/schemas/SpotPriceAdditionalPriceComponentMetadata" + - $ref: "#/components/schemas/SpotPriceAdditionalPercentageComponentMetadata" + - $ref: "#/components/schemas/DurationFeeComponentMetadata" + - $ref: "#/components/schemas/IdleFeeComponentMetadata" + - $ref: "#/components/schemas/TariffComponentMetadata" + - $ref: "#/components/schemas/DefaultComponentMetadata" ComponentMetadataTypeDto: type: string description: "Enumerate the various types of metadata.The content of metadata\ @@ -8747,12 +13258,14 @@ components: - fixed-charging-fee - idle-fee - adjustment + - bilateral-agreement - other Consumer: required: - clientId - createdAt - name + - operatorIds - scopes - teamIds type: object @@ -8766,10 +13279,18 @@ components: description: Your operator id format: int64 example: 42 + operatorIds: + type: array + description: "List of operator ids that are authorized for API operations.\ + \ If empty, all child operators of this operator are authorized." + items: + type: integer + format: int64 + example: 42 teamIds: type: array - description: "List of team ids that are unlocked for API operations. If\ - \ empty, all teams of this operator are unlocked." + description: "List of team ids that are authorized for API operations. If\ + \ empty, all teams of this operator are authorized." items: type: integer format: int64 @@ -8885,10 +13406,11 @@ components: nullable: true example: GB level: + description: The level of depth for this country area + example: bidding-area allOf: - - $ref: '#/components/schemas/CountryAreaLevel' - - description: The level of depth for this country area - example: bidding-area + - $ref: "#/components/schemas/CountryAreaLevel" + - {} CountryAreaLevel: type: string enum: @@ -8903,16 +13425,25 @@ components: type: object properties: type: + description: Type of the additional pricing. `absolute` means the value + is a price. + example: percentage allOf: - - $ref: '#/components/schemas/AdditionalPricingType' - - description: Type of the additional pricing. `absolute` means the value - is a price. - example: percentage + - $ref: "#/components/schemas/AdditionalPricingType" + - {} value: + minimum: 0 + exclusiveMinimum: true required: - "true" type: number description: The value of this additional pricing. + title: + required: + - "false" + type: string + description: A title for this additional pricing. + nullable: true CreateChargeAuthToken: required: - identifier @@ -8947,10 +13478,11 @@ components: \ e.g `VID:`" example: 38C58DB85F4 type: + description: Type of the charge auth token + example: vehicleId allOf: - - $ref: '#/components/schemas/ChargeAuthenticationType' - - description: Type of the charge auth token - example: vehicleId + - $ref: "#/components/schemas/ChargeAuthenticationType" + - {} name: type: string description: Name of the charge auth token @@ -9055,15 +13587,17 @@ components: format: double example: 22 visibility: + description: Visibility type of the charge point + example: private allOf: - - $ref: '#/components/schemas/VisibilityType' - - description: Visibility type of the charge point - example: private + - $ref: "#/components/schemas/VisibilityType" + - {} type: + description: Electric current type the charge point support + example: ac allOf: - - $ref: '#/components/schemas/ElectricCurrentType' - - description: Electric current type the charge point support - example: ac + - $ref: "#/components/schemas/ElectricCurrentType" + - {} active: type: boolean description: Indicates the charge point is active @@ -9085,7 +13619,11 @@ components: \ \n When not present the provide charge point model connectors\ \ will be used instead. \n " nullable: true - example: "[1,2,3,4]" + example: + - 1 + - 2 + - 3 + - 4 items: type: integer format: int64 @@ -9209,14 +13747,16 @@ components: description: Name of the price group example: Public Price Group type: + description: Type of the price group + example: public allOf: - - $ref: '#/components/schemas/PriceGroupType' - - description: Type of the price group - example: public + - $ref: "#/components/schemas/PriceGroupType" + - {} masterPrice: + description: The master price allOf: - - $ref: '#/components/schemas/CreateOrUpdatePricingDto' - - description: The master price + - $ref: "#/components/schemas/CreateOrUpdatePricingDto" + - {} fees: required: - "false" @@ -9224,7 +13764,7 @@ components: description: All the fees for the price group nullable: true items: - $ref: '#/components/schemas/CreateOrUpdatePricingDto' + $ref: "#/components/schemas/CreateOrUpdatePricingDto" CreateOrUpdatePricingDto: required: - endAtFullyCharged @@ -9241,11 +13781,12 @@ components: nullable: true example: Starting Fee type: + description: Type of the pricing. `minute` is used for Minute fee. `min` + is used for the master price. + example: kwh allOf: - - $ref: '#/components/schemas/PricingType' - - description: Type of the pricing. `minute` is used for Minute fee. `min` - is used for the master price. - example: kwh + - $ref: "#/components/schemas/PricingType" + - {} endAtFullyCharged: required: - "true" @@ -9334,7 +13875,7 @@ components: values to be added on top of the previous calculations nullable: true items: - $ref: '#/components/schemas/CreateAdditionalPricingDto' + $ref: "#/components/schemas/CreateAdditionalPricingDto" from: required: - "false" @@ -9400,15 +13941,17 @@ components: description: Name of the site example: Monta CPH Site address: + description: "Address of the site, Note: please ensure to always provide\ + \ a valid address" allOf: - - $ref: '#/components/schemas/CreatedOrUpdateAddress' - - description: "Address of the site, Note: please ensure to always provide\ - \ a valid address" + - $ref: "#/components/schemas/CreatedOrUpdateAddress" + - {} visibility: + description: Visibility type of the site + example: private allOf: - - $ref: '#/components/schemas/VisibilityType_1' - - description: Visibility type of the site - example: private + - $ref: "#/components/schemas/VisibilityType_1" + - {} partnerExternalId: type: string description: "External Id of this entity, managed by you." @@ -9460,10 +14003,11 @@ components: nullable: true example: 1 payoutSchedule: + description: The payout schedule for this sponsored charge point + example: realtime allOf: - - $ref: '#/components/schemas/SponsoredChargePointPayoutType' - - description: The payout schedule for this sponsored charge point - example: realtime + - $ref: "#/components/schemas/SponsoredChargePointPayoutType" + - {} payForSubscriptions: type: boolean description: Indicates that company pay for subscriptions @@ -9480,33 +14024,32 @@ components: type: integer description: Id of the plan to subscribe to format: int64 - customerType: - allOf: - - $ref: '#/components/schemas/SubscriptionCustomerType' - - description: Type of customer the subscription is created for.Currently - you can create subscriptions for charge-points only. customerId: minimum: 0 exclusiveMinimum: true type: integer - description: "Id of the customer the subscription is created for, e.g. a\ - \ chargePointId" + description: "Id of the customer the subscription is created for, e.g. team\ + \ or charge-point id" format: int64 + customerType: + description: Type of the customer that the subscription is created for. + e.g. team or charge-point + allOf: + - $ref: "#/components/schemas/SubscriptionCustomerType" + - {} discountAbsolute: minimum: 0 - exclusiveMinimum: true required: - "false" type: number description: "Allows to modify the absolute discount on a subscription if\ - \ provided.\n If not provided, the discount of the plan is\ + \ provided. \n If not provided, the discount of the plan is\ \ used.\n Note: If you want to set it on an existing subscription,\ \ you have to cancel the subscription first.\n " format: double nullable: true discountPercentage: minimum: 0 - exclusiveMinimum: true required: - "false" type: number @@ -9517,11 +14060,23 @@ components: format: double nullable: true serviceConfig: + description: "Configure the subscription, based on the plans serviceType.Currently\ + \ you can configure tax-refund subscriptions only." nullable: true allOf: - - $ref: '#/components/schemas/SubscriptionServiceConfig' - - description: "Configure the subscription, based on the plans serviceType.Currently\ - \ you can configure tax-refund subscriptions only." + - $ref: "#/components/schemas/SubscriptionServiceConfig" + - {} + userId: + minimum: 0 + exclusiveMinimum: true + required: + - "false" + type: integer + description: "The user that should be assigned as the purchaser of the subscription.\ + \ If not provided, the subscription will be assigned to the default user\ + \ for this consumer." + format: int64 + nullable: true CreateTariffPricesRequest: required: - end @@ -9616,14 +14171,17 @@ components: - "true" type: array description: Zip codes where this tariff is applicable - example: "[\"2200\", \"2100\"]" + example: + - "2200" + - "2100" items: type: string tariffType: + description: Dynamic or weekly + example: WEEKLY allOf: - - $ref: '#/components/schemas/TariffType' - - description: Dynamic or weekly - example: WEEKLY + - $ref: "#/components/schemas/TariffType" + - {} active: required: - "false" @@ -9643,11 +14201,12 @@ components: description: Human description of the area the tariff is active in example: Fyn customerType: + description: What kind of customer types are the tariff for? nullable: true + example: C_CUSTOMER allOf: - - $ref: '#/components/schemas/TariffCustomerType' - - description: What kind of customer types are the tariff for? - example: c_customer + - $ref: "#/components/schemas/TariffCustomerType" + - {} CreateTeamDto: required: - address @@ -9664,11 +14223,22 @@ components: example: 42 userEmail: type: string - description: "email of the user that owns the team, useful when the userId\ + description: "Email of the user that owns the team, useful when the userId\ \ is not known" format: email nullable: true - example: user@monta.com + example: user@monta.com + operatorId: + minimum: 0 + exclusiveMinimum: true + type: integer + description: "Id of the operator this team should be assigned to
*Note*:\ + \ if not provided the team will be assigned to the default operator for\ + \ the given consumer, if the default operator cannot be assigned the request\ + \ will be rejected." + format: int64 + nullable: true + example: 1 name: minLength: 1 type: string @@ -9680,15 +14250,16 @@ components: format: email example: contact@monta.com type: + description: type of the team + example: private allOf: - - $ref: '#/components/schemas/TeamType.Creatable' - - description: type of the team - example: private + - $ref: "#/components/schemas/TeamType.Creatable" + - {} address: + description: "Address of the team, Note: be sure to add always a valid address" allOf: - - $ref: '#/components/schemas/CreatedOrUpdateAddress' - - description: "Address of the team, Note: be sure to add always a valid\ - \ address" + - $ref: "#/components/schemas/CreatedOrUpdateAddress" + - {} companyName: type: string description: The company name for the team @@ -9752,10 +14323,11 @@ components: nullable: true example: "+45123456789" role: + description: Role for this member within the team + example: admin allOf: - - $ref: '#/components/schemas/TeamMemberRole' - - description: Role for this member within the team - example: admin + - $ref: "#/components/schemas/TeamMemberRole" + - {} priceGroupId: type: integer description: "The price group for this team member, when not provided the\ @@ -9763,6 +14335,24 @@ components: format: int64 nullable: true example: 1 + costGroupId: + type: integer + description: The cost group for this team member + format: int64 + nullable: true + example: 1 + teamMemberProfileId: + type: integer + description: The team member profile id to apply to this team member + format: int64 + nullable: true + example: 1 + canConfigureChargePoints: + type: boolean + description: Indicates if the team member access to pay with team wallet + when charging + example: false + default: false canPayWithTeamWallet: type: boolean description: Gives the team member access to pay with team wallet when charging @@ -9782,13 +14372,24 @@ components: teamWalletChargePaymentType: nullable: true allOf: - - $ref: '#/components/schemas/TeamWalletChargePaymentType' + - $ref: "#/components/schemas/TeamWalletChargePaymentType" canManageTeamWallet: type: boolean description: Gives the team member access to withdraw and deposit from your team wallet to your bank account example: false default: false + canPayForChargesCountryIds: + type: array + description: List of country ids for which the team member can pay for charges + nullable: true + example: + - 1 + - 2 + - 3 + items: + type: integer + format: int32 note: type: string description: A note for the team member @@ -9800,7 +14401,11 @@ components: type: array description: Ids of the charge point this team member with will have access nullable: true - example: "[1,2,3,4]" + example: + - 1 + - 2 + - 3 + - 4 items: type: integer format: int64 @@ -9815,59 +14420,331 @@ components: nullable: true items: type: object + CreateTeamMemberProfile: + required: + - canPayForChargesCountryIds + - description + - name + - role + - teamWalletChargePaymentType + type: object + properties: + teamId: + minimum: 0 + exclusiveMinimum: true + type: integer + description: Id of the team + format: int64 + example: 1 + name: + type: string + description: The team member profile name + example: Example profile 1 + description: + type: string + description: The team member profile description + example: Example profile 1 + role: + description: Role for team member profile + example: admin + allOf: + - $ref: "#/components/schemas/TeamMemberRole" + - {} + priceGroupId: + type: integer + description: "The price group, when not provided the default team price\ + \ group will be applied" + format: int64 + nullable: true + example: 1 + costGroupId: + type: integer + description: The cost group + format: int64 + nullable: true + example: 1 + canConfigureChargePoints: + type: boolean + description: Allows the team applying member profile to configure charge + points + example: false + default: false + canPayWithTeamWallet: + type: boolean + description: Gives the team applying member profile access to pay with team + wallet when charging + example: false + default: false + canRequestSponsoring: + type: boolean + description: Allows the team applying member profile to request sponsoring + from this team for their charge point + example: false + default: false + canManageTeamMembers: + type: boolean + description: Allows the team applying member profile to view and manage + other members settings + example: false + default: false + teamWalletChargePaymentType: + $ref: "#/components/schemas/TeamWalletChargePaymentType" + canManageTeamWallet: + type: boolean + description: Gives the team member access to withdraw and deposit from your + team wallet to your bank account + example: false + default: false + canPayForChargesCountryIds: + type: array + description: List of country ids for which the team member can pay for charges + example: + - 1 + - 2 + - 3 + items: + type: integer + format: int32 CreatedOrUpdateAddress: required: - - address1 - - city - - countryId - - zipCode + - address1 + - city + - countryId + - zipCode + type: object + properties: + address1: + minLength: 1 + required: + - "true" + type: string + description: First line of address + example: Strandboulevarden 122 + address2: + minimum: 1 + required: + - "false" + type: string + description: Second line of address + nullable: true + example: København + address3: + minimum: 1 + required: + - "false" + type: string + description: Third line of address + nullable: true + example: 5. sal + city: + minLength: 1 + type: string + description: The city name + example: Berlin + zipCode: + minLength: 1 + required: + - "true" + type: string + description: The address zip code + example: "10011" + countryId: + minimum: 0 + exclusiveMinimum: true + required: + - "true" + type: integer + description: "The country id, Note" + format: int64 + example: 194 + Currency: + required: + - decimals + - identifier + type: object + properties: + id: + minimum: 0 + exclusiveMinimum: true + required: + - "false" + type: integer + description: id of the currency + format: int64 + nullable: true + example: 1 + master: + required: + - "false" + type: boolean + description: "Whether the currency is master or not, master meaning the\ + \ default currency" + example: true + identifier: + maxLength: 3 + minLength: 3 + required: + - "true" + type: string + description: 3 characters identifier + example: DKK + name: + required: + - "false" + type: string + description: Name of the currency + example: Danish krone + decimals: + minimum: 0 + required: + - "true" + type: integer + description: How many decimals the currency has + format: int32 + example: 2 + CurrencyDto: + type: object + properties: + id: + minimum: 0 + exclusiveMinimum: true + required: + - "false" + type: integer + description: id of the currency + format: int64 + nullable: true + example: 1 + identifier: + type: string + description: Currency identifier + nullable: true + example: DKK + name: + type: string + description: Readable name of currency + nullable: true + example: Danish krone + decimals: + type: integer + description: Number of decimals for this currency + format: int32 + example: 2 + Currency_1: + required: + - identifier + - name + type: object + properties: + identifier: + type: string + description: "Currency identifier, e.g. dkk" + example: dkk + name: + type: string + description: Readable name of currency + example: Danish krone + decimals: + type: integer + description: Number of decimals for this currency + format: int32 + example: 2 + Currency_11: + required: + - identifier + - name + type: object + properties: + identifier: + type: string + description: "Currency identifier, e.g. dkk" + example: dkk + name: + type: string + description: Readable name of currency + example: Danish krone + decimals: + type: integer + description: Number of decimals for this currency + format: int32 + example: 2 + Currency_13: + required: + - identifier + - name + type: object + properties: + identifier: + type: string + description: "Currency identifier, e.g. dkk" + example: dkk + name: + type: string + description: Readable name of currency + example: Danish krone + decimals: + type: integer + description: Number of decimals for this currency + format: int32 + example: 2 + Currency_14: + required: + - identifier + - name + type: object + properties: + identifier: + type: string + description: "Currency identifier, e.g. dkk" + example: dkk + name: + type: string + description: Readable name of currency + example: Danish krone + decimals: + type: integer + description: Number of decimals for this currency + format: int32 + example: 2 + Currency_17: + required: + - identifier + - name type: object properties: - address1: - minLength: 1 - required: - - "true" - type: string - description: First line of address - example: Strandboulevarden 122 - address2: - minLength: 1 - required: - - "false" + identifier: type: string - description: Second line of address - nullable: true - example: København - address3: - minLength: 1 - required: - - "false" + description: "Currency identifier, e.g. dkk" + example: dkk + name: type: string - description: Third line of address - nullable: true - example: 5. sal - city: - minLength: 1 + description: Readable name of currency + example: Danish krone + decimals: + type: integer + description: Number of decimals for this currency + format: int32 + example: 2 + Currency_3: + required: + - identifier + - name + type: object + properties: + identifier: type: string - description: The city name - example: Berlin - zipCode: - minLength: 1 - required: - - "true" + description: "Currency identifier, e.g. dkk" + example: dkk + name: type: string - description: The address zip code - example: "10011" - countryId: - minimum: 0 - exclusiveMinimum: true - required: - - "true" + description: Readable name of currency + example: Danish krone + decimals: type: integer - description: "The country id, Note" - format: int64 - example: 194 - Currency: + description: Number of decimals for this currency + format: int32 + example: 2 + Currency_5: required: - identifier - name @@ -9886,56 +14763,38 @@ components: description: Number of decimals for this currency format: int32 example: 2 - CurrencyDto_3: + Currency_7: + required: + - identifier + - name type: object properties: - id: - minimum: 0 - exclusiveMinimum: true - required: - - "false" - type: integer - description: id of the currency - format: int64 - nullable: true - example: 1 identifier: type: string - description: "Currency identifier, e.g. DKK" - nullable: true - example: DKK + description: "Currency identifier, e.g. dkk" + example: dkk name: type: string description: Readable name of currency - nullable: true example: Danish krone decimals: type: integer description: Number of decimals for this currency format: int32 example: 2 - CurrencyDto_4: + Currency_9: + required: + - identifier + - name type: object properties: - id: - minimum: 0 - exclusiveMinimum: true - required: - - "false" - type: integer - description: id of the currency - format: int64 - nullable: true - example: 1 identifier: type: string - description: "Currency identifier, e.g. DKK" - nullable: true - example: DKK + description: "Currency identifier, e.g. dkk" + example: dkk name: type: string description: Readable name of currency - nullable: true example: Danish krone decimals: type: integer @@ -9958,10 +14817,11 @@ components: type: object properties: type: + description: The type of this metadata entry + example: default allOf: - - $ref: '#/components/schemas/ComponentMetadataTypeDto' - - description: The type of this metadata entry - example: default + - $ref: "#/components/schemas/ComponentMetadataTypeDto" + - {} kwh: type: number description: The kwh for this metadata entry @@ -9984,14 +14844,16 @@ components: type: object properties: summary: + description: The summary of the total prices for this breakdown allOf: - - $ref: '#/components/schemas/BreakdownSummary' - - description: The summary of the total prices for this breakdown + - $ref: "#/components/schemas/BreakdownSummary" + - {} currency: + description: "The currency applicable for this breakdown (for all the components:\ + \ prices, fees, adjustments)" allOf: - - $ref: '#/components/schemas/Currency' - - description: "The currency applicable for this breakdown (for all the\ - \ components: prices, fees, adjustments)" + - $ref: "#/components/schemas/Currency_9" + - {} breakdown: required: - "true" @@ -9999,21 +14861,21 @@ components: description: "The breakdown entries for this breakdown, currently organized\ \ on an hourly basis" items: - $ref: '#/components/schemas/Breakdown' + $ref: "#/components/schemas/Breakdown" fees: required: - "true" type: array description: The fees that compose this breakdown items: - $ref: '#/components/schemas/Component' + $ref: "#/components/schemas/Component" adjustments: required: - "true" type: array description: The adjustments applied for this breakdown items: - $ref: '#/components/schemas/Component' + $ref: "#/components/schemas/Component" DriverReportDatesFilteredBy: type: string enum: @@ -10025,10 +14887,11 @@ components: type: object properties: type: + description: The type of this metadata entry + example: default-metadata allOf: - - $ref: '#/components/schemas/ComponentMetadataTypeDto' - - description: The type of this metadata entry - example: default-metadata + - $ref: "#/components/schemas/ComponentMetadataTypeDto" + - {} totalMinutes: type: number description: The total duration in minutes for this metadata entry @@ -10041,9 +14904,14 @@ components: example: 10 ElectricCurrentType: type: string + description: "definitions: \n* `ac` - Indicates the charge point use `ac` (alternating\ + \ current) as electric current. \n* `dc` - Indicates the charge point use\ + \ `ac` (direct current) as electric current. \n* `other` - Indicates the team\ + \ member has only access to the selected charge points. \n" enum: - ac - dc + - other FullTariff: required: - prices @@ -10051,19 +14919,21 @@ components: type: object properties: tariff: + description: tariff allOf: - - $ref: '#/components/schemas/TariffDto' - - description: tariff + - $ref: "#/components/schemas/TariffDto" + - {} prices: type: array description: list of the tariff prices items: - $ref: '#/components/schemas/Price' + $ref: "#/components/schemas/Price" priceSpecification: + description: Price specification nullable: true allOf: - - $ref: '#/components/schemas/PriceSpecification' - - description: Price specification + - $ref: "#/components/schemas/PriceSpecification" + - {} GenericPaymentSession: required: - externalId @@ -10097,6 +14967,12 @@ components: or `cardLast4`. nullable: true example: "1234" + amount: + type: number + description: The amount of the payment session. Negative amounts will be + rejected by the API + nullable: true + example: 1234 IdleFeeComponentMetadata: required: - from @@ -10105,14 +14981,16 @@ components: type: object properties: type: + description: The type of this metadata entry + example: default-metadata allOf: - - $ref: '#/components/schemas/ComponentMetadataTypeDto' - - description: The type of this metadata entry - example: default-metadata + - $ref: "#/components/schemas/ComponentMetadataTypeDto" + - {} amountPerMinute: type: integer description: The idle fee per minute for this metadata entry format: int64 + example: null minutes: type: number description: For how long the the charge stayed idle after fully charged @@ -10147,9 +15025,10 @@ components: format: int64 example: 22 operator: + description: The operator of this installer job allOf: - - $ref: '#/components/schemas/Operator' - - description: The operator of this installer job + - $ref: "#/components/schemas/Operator" + - {} teamId: type: integer description: Id of the team of this installer job @@ -10185,7 +15064,7 @@ components: type: array description: List of tasks of this installer job items: - $ref: '#/components/schemas/InstallerJobTask' + $ref: "#/components/schemas/InstallerJobTask" completedAt: type: string description: Date this installer job was completed @@ -10272,6 +15151,99 @@ components: format: date-time nullable: true example: 2022-05-12T15:56:45.99Z + InvoiceDto: + required: + - createdAt + - currency + - dueAt + - from + - id + - status + - to + - totalPayableBalance + - walletId + type: object + properties: + id: + required: + - "true" + type: integer + description: Id of the invoice + format: int64 + example: 123 + walletId: + required: + - "true" + type: integer + description: Id of the wallet + format: int64 + example: 123 + from: + required: + - "true" + type: string + description: Invoice from date + format: date-time + example: 2024-03-01T00:00:00Z + to: + required: + - "true" + type: string + description: Invoice to date + format: date-time + example: 2024-03-30T00:00:00Z + approvedAt: + required: + - "false" + type: string + description: The date it was approved + format: date-time + nullable: true + example: 2024-03-30T00:00:00Z + totalStatement: + type: number + description: Total statement + nullable: true + example: 12.22 + totalPayableBalance: + type: number + description: Total payable balance + example: 12.22 + currency: + description: Currency + allOf: + - $ref: "#/components/schemas/CurrencyDto" + - {} + status: + type: string + description: status of the invoice + example: paid + enum: + - paid + - unpaid + - settled + createdAt: + required: + - "true" + type: string + description: Invoice creation date + format: date-time + example: 2024-03-30T00:00:00Z + dueAt: + required: + - "true" + type: string + description: Invoice due date + format: date-time + nullable: true + example: 2024-03-30T00:00:00Z + pdfUrl: + required: + - "false" + type: string + description: URL to the invoice PDF + nullable: true + example: https://monta.imgix.net/production/wallet/invoices/xyxy.pdf KafkaEventType: type: string enum: @@ -10297,15 +15269,17 @@ components: type: object properties: coordinates: + description: "Coordinates (lat, lng)" nullable: true allOf: - - $ref: '#/components/schemas/Coordinates' - - description: "Coordinates (lat, lng)" + - $ref: "#/components/schemas/Coordinates" + - {} address: + description: Address nullable: true allOf: - - $ref: '#/components/schemas/Address' - - description: Address + - $ref: "#/components/schemas/Address" + - {} MapResult: required: - chargePoints @@ -10315,16 +15289,20 @@ components: properties: chargePoints: type: array + description: list of all charge points found in that area items: - $ref: '#/components/schemas/MapResultChargePoint' + $ref: "#/components/schemas/MapResultChargePoint" sites: type: array + description: list of all sites found in that area items: - $ref: '#/components/schemas/MapResultSite' + $ref: "#/components/schemas/MapResultSite" cluster: type: array + description: list of all clusters (of charge points and sites) found in + that area items: - $ref: '#/components/schemas/MapResultCluster' + $ref: "#/components/schemas/MapResultCluster" MapResultChargePoint: required: - connectors @@ -10399,19 +15377,21 @@ components: - passive - other location: + description: Location information for this charge point allOf: - - $ref: '#/components/schemas/Location' - - description: Location information for this charge point + - $ref: "#/components/schemas/Location" + - {} connectors: type: array description: "List of supported connector types at this charge point (e.g.\ \ type-2, ccs, ...)" items: - $ref: '#/components/schemas/ChargePointConnector' + $ref: "#/components/schemas/ChargePointConnector" deeplinks: + description: Deeplinks to open charge screen in Monta app or web. allOf: - - $ref: '#/components/schemas/ChargePointDeeplinks' - - description: Deeplinks to open charge screen in Monta app or web. + - $ref: "#/components/schemas/ChargePointDeeplinks" + - {} description: Reduced model of Charge Point MapResultCluster: required: @@ -10419,9 +15399,10 @@ components: type: object properties: coordinates: + description: Coordinates of the cluster allOf: - - $ref: '#/components/schemas/Coordinates' - - description: Coordinates of the cluster + - $ref: "#/components/schemas/Coordinates" + - {} count: type: integer description: Number of entities (Charge points and sites) clustered. @@ -10485,26 +15466,27 @@ components: nullable: true example: In order to access this site enter 0000 as code at the gate. location: + description: Location information for this site allOf: - - $ref: '#/components/schemas/Location' - - description: Location information for this site + - $ref: "#/components/schemas/Location" + - {} connectors: type: array description: "List of supported connector types at this site (e.g. type-2,\ \ ccs, ...)" items: - $ref: '#/components/schemas/ChargePointConnector' + $ref: "#/components/schemas/ChargePointConnector" description: Reduced model of Site MetadataDto: type: object discriminator: propertyName: type mapping: - tax-refund-metadata: '#/components/schemas/TaxRefundMetadata' - charge-metadata: '#/components/schemas/ChargeMetadata' + tax-refund-metadata: "#/components/schemas/TaxRefundMetadata" + charge-metadata: "#/components/schemas/ChargeMetadata" oneOf: - - $ref: '#/components/schemas/TaxRefundMetadata' - - $ref: '#/components/schemas/ChargeMetadata' + - $ref: "#/components/schemas/TaxRefundMetadata" + - $ref: "#/components/schemas/ChargeMetadata" MetadataTypeDto: type: string enum: @@ -10526,9 +15508,10 @@ components: format: int64 example: 12312 currency: + description: Currency allOf: - - $ref: '#/components/schemas/Currency' - - description: Currency + - $ref: "#/components/schemas/Currency" + - {} locale: minLength: 1 required: @@ -10544,7 +15527,7 @@ components: type: object properties: status: - $ref: '#/components/schemas/MontaHttpStatus' + $ref: "#/components/schemas/MontaHttpStatus" message: type: string nullable: true @@ -10566,7 +15549,7 @@ components: type: array nullable: true items: - $ref: '#/components/schemas/MontaAppResponse.ErrorDetail' + $ref: "#/components/schemas/MontaAppResponse.ErrorDetail" statusCode: type: integer format: int32 @@ -10589,7 +15572,7 @@ components: type: array nullable: true items: - $ref: '#/components/schemas/MontaAppResponse.ErrorDetail.Body' + $ref: "#/components/schemas/MontaAppResponse.ErrorDetail.Body" MontaAppResponse.ErrorDetail.Body: required: - message @@ -10701,9 +15684,9 @@ components: data: type: array items: - $ref: '#/components/schemas/ChargeAuthToken' + $ref: "#/components/schemas/ChargeAuthToken" meta: - $ref: '#/components/schemas/MontaPage.Meta' + $ref: "#/components/schemas/MontaPage.Meta" MontaPage_ChargeDto_: required: - data @@ -10713,10 +15696,106 @@ components: data: type: array items: - $ref: '#/components/schemas/Charge' + $ref: "#/components/schemas/Charge" + meta: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargePointBrandDto_: + required: + - data + - meta + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/ChargePointBrand" + meta: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargePointConnectorDto_: + required: + - data + - meta + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/ChargePointConnector" + meta: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargePointDto_: + required: + - data + - meta + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/ChargePoint" + meta: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargePointIntegrationDto_: + required: + - data + - meta + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/ChargePointIntegration" + meta: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargePointModelDto_: + required: + - data + - meta + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/ChargePointModel" + meta: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargePointOcppLogDto_: + required: + - data + - meta + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/ChargePointOcppLog" + meta: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargesInsightByChargeAuthTokenReportDto_: + required: + - data + - meta + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/ChargesInsightByChargeAuthTokenReportDto" + meta: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargesInsightChargerReportDto_: + required: + - data + - meta + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/ChargesInsightChargerReport" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_ChargePointBrandDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargesInsightDriverMemberCostsReportDto_: required: - data - meta @@ -10725,10 +15804,10 @@ components: data: type: array items: - $ref: '#/components/schemas/ChargePointBrand' + $ref: "#/components/schemas/ChargesInsightDriverMemberCostsReport" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_ChargePointConnectorDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ChargesInsightDriverReportDto_: required: - data - meta @@ -10737,10 +15816,10 @@ components: data: type: array items: - $ref: '#/components/schemas/ChargePointConnector' + $ref: "#/components/schemas/ChargesInsightDriverReport" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_ChargePointDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_CountryAreaDto_: required: - data - meta @@ -10749,10 +15828,10 @@ components: data: type: array items: - $ref: '#/components/schemas/ChargePoint' + $ref: "#/components/schemas/CountryArea" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_ChargePointIntegrationDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_CountryDto_: required: - data - meta @@ -10761,10 +15840,10 @@ components: data: type: array items: - $ref: '#/components/schemas/ChargePointIntegration' + $ref: "#/components/schemas/Country" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_ChargePointModelDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_CurrencyDto_: required: - data - meta @@ -10773,10 +15852,10 @@ components: data: type: array items: - $ref: '#/components/schemas/ChargePointModel' + $ref: "#/components/schemas/CurrencyDto" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_ChargesInsightChargerReportDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_InstallerJobDto_: required: - data - meta @@ -10785,10 +15864,10 @@ components: data: type: array items: - $ref: '#/components/schemas/ChargesInsightChargerReport' + $ref: "#/components/schemas/InstallerJob" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_ChargesInsightDriverReportDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_InvoiceDto_: required: - data - meta @@ -10797,10 +15876,10 @@ components: data: type: array items: - $ref: '#/components/schemas/ChargesInsightDriverReport' + $ref: "#/components/schemas/InvoiceDto" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_CountryAreaDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_NestedTeamDto_: required: - data - meta @@ -10809,10 +15888,10 @@ components: data: type: array items: - $ref: '#/components/schemas/CountryArea' + $ref: "#/components/schemas/NestedTeam" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_CountryDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_OperatorDto_: required: - data - meta @@ -10821,10 +15900,10 @@ components: data: type: array items: - $ref: '#/components/schemas/Country' + $ref: "#/components/schemas/Operator" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_CurrencyDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_PaymentTerminalDto_: required: - data - meta @@ -10833,10 +15912,10 @@ components: data: type: array items: - $ref: '#/components/schemas/CurrencyDto_3' + $ref: "#/components/schemas/PaymentTerminal" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_InstallerJobDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_PlanDto_: required: - data - meta @@ -10845,10 +15924,10 @@ components: data: type: array items: - $ref: '#/components/schemas/InstallerJob' + $ref: "#/components/schemas/Plan" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_OperatorDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_PriceGroupDto_: required: - data - meta @@ -10857,10 +15936,10 @@ components: data: type: array items: - $ref: '#/components/schemas/Operator' + $ref: "#/components/schemas/PriceGroup" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_PaymentTerminalDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_PriceGroupTagDto_: required: - data - meta @@ -10869,10 +15948,10 @@ components: data: type: array items: - $ref: '#/components/schemas/PaymentTerminal' + $ref: "#/components/schemas/PriceGroupTag" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_PlanDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_ReportDto_: required: - data - meta @@ -10881,10 +15960,10 @@ components: data: type: array items: - $ref: '#/components/schemas/Plan' + $ref: "#/components/schemas/ReportDto" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_PriceGroupDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_SiteDto_: required: - data - meta @@ -10893,10 +15972,10 @@ components: data: type: array items: - $ref: '#/components/schemas/PriceGroup' + $ref: "#/components/schemas/Site" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_PriceGroupTagDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_SponsoredChargePointDto_: required: - data - meta @@ -10905,10 +15984,10 @@ components: data: type: array items: - $ref: '#/components/schemas/PriceGroupTag' + $ref: "#/components/schemas/SponsoredChargePoint" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_SiteDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_SubscriptionDto_: required: - data - meta @@ -10917,10 +15996,10 @@ components: data: type: array items: - $ref: '#/components/schemas/Site' + $ref: "#/components/schemas/Subscription" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_SponsoredChargePointDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_SubscriptionPurchaseDto_: required: - data - meta @@ -10929,10 +16008,10 @@ components: data: type: array items: - $ref: '#/components/schemas/SponsoredChargePoint' + $ref: "#/components/schemas/SubscriptionPurchase" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_SubscriptionDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_TeamDto_: required: - data - meta @@ -10941,10 +16020,10 @@ components: data: type: array items: - $ref: '#/components/schemas/Subscription' + $ref: "#/components/schemas/Team" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_SubscriptionPurchaseDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_TeamMemberDto_: required: - data - meta @@ -10953,10 +16032,10 @@ components: data: type: array items: - $ref: '#/components/schemas/SubscriptionPurchase' + $ref: "#/components/schemas/TeamMember" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_TeamDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_TeamMemberProfileDto_: required: - data - meta @@ -10965,10 +16044,10 @@ components: data: type: array items: - $ref: '#/components/schemas/Team' + $ref: "#/components/schemas/TeamMemberProfile" meta: - $ref: '#/components/schemas/MontaPage.Meta' - MontaPage_TeamMemberDto_: + $ref: "#/components/schemas/MontaPage.Meta" + MontaPage_UserDto_: required: - data - meta @@ -10977,9 +16056,9 @@ components: data: type: array items: - $ref: '#/components/schemas/TeamMemberDto' + $ref: "#/components/schemas/User" meta: - $ref: '#/components/schemas/MontaPage.Meta' + $ref: "#/components/schemas/MontaPage.Meta" MontaPage_WalletDto_: required: - data @@ -10989,9 +16068,9 @@ components: data: type: array items: - $ref: '#/components/schemas/Wallet' + $ref: "#/components/schemas/Wallet" meta: - $ref: '#/components/schemas/MontaPage.Meta' + $ref: "#/components/schemas/MontaPage.Meta" MontaPage_WalletTransactionDto_: required: - data @@ -11001,9 +16080,9 @@ components: data: type: array items: - $ref: '#/components/schemas/WalletTransaction' + $ref: "#/components/schemas/WalletTransaction" meta: - $ref: '#/components/schemas/MontaPage.Meta' + $ref: "#/components/schemas/MontaPage.Meta" MontaPage_WebhookEntryDto_: required: - data @@ -11013,9 +16092,142 @@ components: data: type: array items: - $ref: '#/components/schemas/WebhookEntry' + $ref: "#/components/schemas/WebhookEntry" meta: - $ref: '#/components/schemas/MontaPage.Meta' + $ref: "#/components/schemas/MontaPage.Meta" + NestedTeam: + required: + - access + - createdAt + - parentTeam + - state + - userRole + type: object + properties: + id: + type: integer + description: Id of the nested team relation + format: int64 + example: 1 + parentTeam: + description: "Parent team, the one who sends the invite" + allOf: + - $ref: "#/components/schemas/PublicTeam" + - {} + nestedTeam: + description: "Parent team, the one who receives the invite" + nullable: true + allOf: + - $ref: "#/components/schemas/PublicTeam" + - {} + priceGroup: + description: Price group applied to the nested team + nullable: true + allOf: + - $ref: "#/components/schemas/PriceGroup_1" + - {} + invitedByUser: + description: User who requested the invitation + nullable: true + allOf: + - $ref: "#/components/schemas/PublicUser" + - {} + userRole: + type: string + description: The role assigned to the nested team + example: user + enum: + - user + access: + description: "Access to parent team CPs / sites: to all or selected charge\ + \ points and/or sites" + example: all + allOf: + - $ref: "#/components/schemas/TeamMemberAccess" + - {} + state: + description: State of the nested team invitation + example: accepted + allOf: + - $ref: "#/components/schemas/TeamMemberState" + - {} + selectedChargePointIds: + type: array + description: Selected charge points nested team has access to + nullable: true + example: + - 41 + - 72 + - 93 + items: + type: integer + format: int64 + note: + type: string + description: Internal note for this nested team + nullable: true + example: Internal note placeholder + createdAt: + type: string + description: Datetime of the creation of nested team invite + format: date-time + example: 2022-07-27T18:11:41Z + updatedAt: + type: string + description: Datetime of the update of nested team invite + format: date-time + nullable: true + example: 2022-07-28T18:11:41Z + invitedAt: + type: string + description: Datetime nested team was invited + format: date-time + nullable: true + example: 2022-07-28T18:11:41Z + NestedTeamInvite: + required: + - access + - nestedTeamId + - parentTeamId + - priceGroupId + type: object + properties: + parentTeamId: + type: integer + description: "Id of the parent team, the one who sends the invite" + format: int64 + example: 1 + nestedTeamId: + type: integer + description: "Id of the nested team, the one who receives the invite" + format: int64 + example: 2 + priceGroupId: + type: integer + description: Price group applied to the nested team + format: int64 + example: 3 + access: + description: Is access granted to all or selected charge points and sites + example: all + allOf: + - $ref: "#/components/schemas/TeamMemberAccess" + - {} + selectedChargePointIds: + type: array + description: List of charge point ids nested team access will be assigned + to + nullable: true + items: + type: integer + format: int64 + selectedSiteIds: + type: array + description: List of site ids nested team access will be assigned to + nullable: true + items: + type: integer + format: int64 Operator: required: - identifier @@ -11040,6 +16252,7 @@ components: description: Partner id (owner of this operator) format: int64 nullable: true + example: null vatNumber: type: string description: VAT number @@ -11074,6 +16287,7 @@ components: type: integer description: Currency identifier format: int64 + example: null amount: type: number description: Amount to transfer @@ -11081,13 +16295,17 @@ components: example: 13.77 partnerExternalId: type: string - description: "External Id of this entity, managed by you." + description: "**Note: This has been deprecated and will be null always.**External\ + \ Id of this entity, managed by you." nullable: true example: ACME-12345 + deprecated: true partnerCustomPayload: type: array - description: "Custom JSON payload for this entity, managed by you." + description: "**Note: This has been deprecated and will be null always.**Custom\ + \ JSON payload for this entity, managed by you." nullable: true + deprecated: true items: type: object OperatorRole: @@ -11099,10 +16317,8 @@ components: Page_TariffRecurringPeriodDto_: type: object allOf: - - $ref: '#/components/schemas/Slice_TariffRecurringPeriodDto_' - - required: - - totalSize - properties: + - $ref: "#/components/schemas/Slice_TariffRecurringPeriodDto_" + - properties: totalSize: type: integer format: int64 @@ -11110,21 +16326,29 @@ components: type: integer format: int32 Pageable: + required: + - size + - sort type: object allOf: - - $ref: '#/components/schemas/Sort' - - required: - - size - - sort - properties: + - $ref: "#/components/schemas/Sort" + - properties: number: type: integer format: int32 size: type: integer format: int32 + mode: + $ref: "#/components/schemas/Pageable.Mode" sort: - $ref: '#/components/schemas/Sort' + $ref: "#/components/schemas/Sort" + Pageable.Mode: + type: string + enum: + - CURSOR_NEXT + - CURSOR_PREVIOUS + - OFFSET Pair_String.BigDecimal_: required: - first @@ -11139,15 +16363,16 @@ components: type: object properties: genericPaymentSession: + description: "For Partners who want to start charging from payment terminals,\ + \ kiosks etc. Used to link charge transaction against your billing and\ + \ to allow users retrieving receipts via receipt.monta.com by using date\ + \ and `genericPaymentSession.externalId`or `genericPaymentSession.cardLast4`.

**Note:\ + \ This field is optional, but if provided, you need to provide the full\ + \ data, since it will be overwritten with values from this object.**" nullable: true allOf: - - $ref: '#/components/schemas/GenericPaymentSession' - - description: "For Partners who want to start charging from payment terminals,\ - \ kiosks etc. Used to link charge transaction against your billing and\ - \ to allow users retrieving receipts via receipt.monta.com by using\ - \ date and `genericPaymentSession.externalId`or `genericPaymentSession.cardLast4`.

**Note:\ - \ This field is optional, but if provided, you need to provide the full\ - \ data, since it will be overwritten with values from this object.**" + - $ref: "#/components/schemas/PatchGenericPaymentSession" + - {} partnerExternalId: type: string description: "External Id of this entity, managed by you." @@ -11251,17 +16476,19 @@ components: nullable: true example: 22 visibility: + description: Visibility type of the charge point nullable: true + example: private allOf: - - $ref: '#/components/schemas/VisibilityType' - - description: Visibility type of the charge point - example: private + - $ref: "#/components/schemas/VisibilityType" + - {} type: + description: Electric current type the charge point support nullable: true + example: ac allOf: - - $ref: '#/components/schemas/ElectricCurrentType' - - description: Electric current type the charge point support - example: ac + - $ref: "#/components/schemas/ElectricCurrentType" + - {} active: type: boolean description: Indicates the charge point is active @@ -11281,7 +16508,11 @@ components: type: array description: Ids of the connectors this charge point support nullable: true - example: "[1,2,3,4]" + example: + - 1 + - 2 + - 3 + - 4 items: type: integer format: int64 @@ -11299,10 +16530,85 @@ components: example: ACME-12345 partnerCustomPayload: type: array - description: "Custom JSON payload for this entity, managed by you." + description: "\n Custom JSON payload managed by you.\n
To\ + \ override default values or provide additional metadata.\n Can\ + \ include keys like `custom_roaming_name` and `custom_roaming_evse_id`\ + \ for roaming charge points,\n if so the fields must follow the\ + \ correct format.\n The payload is limited to 1000 characters overall.\ + \ \n " nullable: true + example: |- + { + "custom_property": "additional_value", + "custom_roaming_name": "Roaming_CP", + "custom_roaming_evse_id": "DE*123*E12345", + } items: type: object + PatchGenericPaymentSession: + required: + - externalId + - provider + type: object + properties: + provider: + type: string + description: The provider of the payment session + example: logos + externalId: + type: string + description: The external id of the payment session. Allows retrieving receipts + via receipt.monta.com by using date and `externalId` or `cardLast4`. + example: | + 76BB1FCF-946D-4040-A8F7-8FD6ECDEE5B1 + partnerExternalId: + type: string + description: "External Id of this entity, managed by you." + nullable: true + example: ACME-12345 + cardBrand: + type: string + description: The brand of the card used for the payment session + nullable: true + example: VISA + cardLast4: + type: string + description: The last 4 digits of the card used for the payment session. + Allows retrieving receipts via receipt.monta.com by using date and `externalId` + or `cardLast4`. + nullable: true + example: "1234" + amount: + type: number + description: The amount of the payment session. Negative amounts will be + rejected by the API + format: double + nullable: true + example: 10.1 + PatchNestedTeam: + type: object + properties: + priceGroupId: + type: integer + description: Price group applied to the nested team + format: int64 + nullable: true + example: 1 + note: + maxLength: 255 + type: string + description: "A note (instructions, warning, information) you have entered\ + \ for this nested team member" + nullable: true + example: A note for nested team member + selectedChargePointIds: + type: array + description: List of charge point ids nested team access will be assigned + to + nullable: true + items: + type: integer + format: int64 PatchPriceGroupTag: type: object properties: @@ -11336,17 +16642,19 @@ components: nullable: true example: Monta CPH Site address: + description: "Address of the site, Note: please ensure to always provide\ + \ a valid address" nullable: true allOf: - - $ref: '#/components/schemas/CreatedOrUpdateAddress' - - description: "Address of the site, Note: please ensure to always provide\ - \ a valid address" + - $ref: "#/components/schemas/CreatedOrUpdateAddress" + - {} visibility: + description: Visibility type of the site nullable: true + example: private allOf: - - $ref: '#/components/schemas/VisibilityType_3' - - description: Visibility type of the site - example: private + - $ref: "#/components/schemas/VisibilityType_3" + - {} partnerExternalId: type: string description: "External Id of this entity, managed by you." @@ -11371,11 +16679,12 @@ components: nullable: true example: 1 payoutSchedule: + description: The payout schedule for this sponsored charge point nullable: true + example: "1" allOf: - - $ref: '#/components/schemas/SponsoredChargePointPayoutType' - - description: The payout schedule for this sponsored charge point - example: "1" + - $ref: "#/components/schemas/SponsoredChargePointPayoutType" + - {} payForSubscriptions: type: boolean description: Indicates that company pay for subscriptions @@ -11412,10 +16721,11 @@ components: nullable: true example: contact@monta.com address: + description: Address of the team nullable: true allOf: - - $ref: '#/components/schemas/CreatedOrUpdateAddress' - - description: Address of the team + - $ref: "#/components/schemas/CreatedOrUpdateAddress" + - {} companyName: type: string description: The company name for the team @@ -11444,22 +16754,46 @@ components: type: array description: Ids of the charge points to patch this team member with nullable: true - example: "[1,2,3,4]" + example: + - 1 + - 2 + - 3 + - 4 items: type: integer format: int64 role: + description: Role for this member within the team nullable: true + example: admin allOf: - - $ref: '#/components/schemas/TeamMemberRole' - - description: Role for this member within the team - example: admin + - $ref: "#/components/schemas/TeamMemberRole" + - {} priceGroupId: type: integer description: The price group for this team member format: int64 nullable: true example: 1 + costGroupId: + type: integer + description: The cost group for this team member + format: int64 + nullable: true + example: 1 + teamMemberProfileId: + type: integer + description: The team member profile id to apply to this team member + format: int64 + nullable: true + example: 1 + canConfigureChargePoints: + type: boolean + description: Indicates if the team member access to pay with team wallet + when charging + nullable: true + example: false + default: false canPayWithTeamWallet: type: boolean description: Gives the team member access to pay with team wallet when charging @@ -11489,7 +16823,18 @@ components: teamWalletChargePaymentType: nullable: true allOf: - - $ref: '#/components/schemas/TeamWalletChargePaymentType' + - $ref: "#/components/schemas/TeamWalletChargePaymentType" + canPayForChargesCountryIds: + type: array + description: List of country ids for which the team member can pay for charges + nullable: true + example: + - 1 + - 2 + - 3 + items: + type: integer + format: int32 note: type: string description: A note for the team member @@ -11506,6 +16851,85 @@ components: nullable: true items: type: object + PatchTeamMemberProfile: + type: object + properties: + name: + type: string + description: Name for the team member profile + nullable: true + example: seasonal offer + description: + type: string + description: Description for the team member profile + nullable: true + example: detail description + role: + description: Role for the team member profile + nullable: true + example: admin + allOf: + - $ref: "#/components/schemas/TeamMemberRole" + - {} + priceGroupId: + type: integer + description: The price group for the team member profile + format: int64 + nullable: true + example: 1 + costGroupId: + type: integer + description: The cost group for the team member profile + format: int64 + nullable: true + example: 1 + canPayWithTeamWallet: + type: boolean + description: Gives the team member access to pay with team wallet when charging + nullable: true + example: false + default: false + canManageTeamWallet: + type: boolean + description: Gives the team member access to withdraw and deposit from your + team wallet to your bank account + nullable: true + example: false + default: false + canRequestSponsoring: + type: boolean + description: Allows the team member to request sponsoring from this team + for their charge point + nullable: true + example: false + default: false + canManageTeamMembers: + type: boolean + description: Allows the team member to view and manage other members settings + nullable: true + example: false + default: false + teamWalletChargePaymentType: + nullable: true + allOf: + - $ref: "#/components/schemas/TeamWalletChargePaymentType" + canConfigureChargePoints: + type: boolean + description: Allows the team member profile to configure charge points + nullable: true + example: false + default: false + canPayForChargesCountryIds: + type: array + description: List of country ids for which the team member can pay for charges + nullable: true + example: + - 1 + - 2 + - 3 + items: + type: integer + format: int32 PatchWalletTransaction: type: object properties: @@ -11554,10 +16978,11 @@ components: description: "Id of this terminal. **NOTE: This is a String**" example: payter_123 type: + description: "Type of this terminal, ie \"payter\"" + example: payter allOf: - - $ref: '#/components/schemas/PaymentTerminalType' - - description: "Type of this terminal, ie \"payter\"" - example: payter + - $ref: "#/components/schemas/PaymentTerminalType" + - {} teamId: type: integer description: The team this terminal belongs to @@ -11611,6 +17036,24 @@ components: enum: - payter - other + Performance: + required: + - status + - usagePercentage + type: object + properties: + status: + required: + - "true" + type: string + description: State of the system or charge point + example: operational + usagePercentage: + required: + - "true" + type: number + description: Percentage of time in this state + example: 75 Plan: required: - active @@ -11692,11 +17135,12 @@ components: nullable: true example: support@acme.com applicableFor: + description: Indicates whether this plan can be applied to teams or charge + points. 'operator' value is only used internally. + example: charge-point allOf: - - $ref: '#/components/schemas/PlanApplicableFor' - - description: Indicates whether this plan can be applied to teams or charge - points. 'operator' value is only used internally. - example: charge-point + - $ref: "#/components/schemas/PlanApplicableFor" + - {} active: required: - "true" @@ -11704,11 +17148,12 @@ components: description: Indicates if the plan is active (only active plans can be applied). example: true applicationAudience: + description: "Indicates whether this plan is shown in your (operator's)\ + \ app only, or in the Monta app as well." + example: all allOf: - - $ref: '#/components/schemas/PlanApplicationAudience' - - description: "Indicates whether this plan is shown in your (operator's)\ - \ app only, or in the Monta app as well." - example: all + - $ref: "#/components/schemas/PlanApplicationAudience" + - {} visibleInMarketPlace: required: - "true" @@ -11717,31 +17162,34 @@ components: not. example: true priceModel: + description: Indicates if the price is per charge point or a fixed price. + example: fixed allOf: - - $ref: '#/components/schemas/PlanPriceModel' - - description: Indicates if the price is per charge point or a fixed price. - example: fixed + - $ref: "#/components/schemas/PlanPriceModel" + - {} prices: required: - "true" type: array description: Active plan prices items: - $ref: '#/components/schemas/PlanPrice' + $ref: "#/components/schemas/PlanPrice" pricesWithVat: required: - "true" type: boolean description: Indicates if the prices are incl. VAT or not. Default is `true`. serviceType: + description: "Plan service type, custom or tax-refund" + example: tax-refund allOf: - - $ref: '#/components/schemas/PlanServiceType' - - description: "Service of the Plan, custom or tax-refund" - example: tax-refund + - $ref: "#/components/schemas/PlanServiceType" + - {} serviceConfig: + description: "Additional configuration, based on serviceType" allOf: - - $ref: '#/components/schemas/PlanServiceConfig' - - description: "Additional configuration, based on serviceType" + - $ref: "#/components/schemas/PlanServiceConfig" + - {} PlanApplicableFor: type: string enum: @@ -11753,6 +17201,11 @@ components: enum: - all - own + PlanCustomAdditionalFeeApplicationScope: + type: string + enum: + - all + - paid PlanPrice: required: - currency @@ -11769,9 +17222,10 @@ components: format: double example: 4.99 currency: + description: Currency for `price`. allOf: - - $ref: '#/components/schemas/Currency' - - description: Currency for `price`. + - $ref: "#/components/schemas/Currency_1" + - {} PlanPriceModel: type: string enum: @@ -11780,14 +17234,22 @@ components: PlanServiceConfig: type: object anyOf: - - $ref: '#/components/schemas/PlanServiceConfigCustom' - - $ref: '#/components/schemas/PlanServiceConfigTaxRefund' + - $ref: "#/components/schemas/PlanServiceConfigCustom" + - $ref: "#/components/schemas/PlanServiceConfigTaxRefund" PlanServiceConfigCustom: required: - additionalFeeAbsolute - additionalFeePercentage + - additionalStartingFee type: object properties: + additionalFeeApplicationScope: + description: Type of charges to which custom additional fees are applied + nullable: true + example: all + allOf: + - $ref: "#/components/schemas/PlanCustomAdditionalFeeApplicationScope" + - {} additionalFeePercentage: required: - "true" @@ -11805,6 +17267,43 @@ components: \ operator.Note: This uses the default currency of the operator!" format: double example: 0.5 + additionalStartingFee: + required: + - "true" + type: number + description: "This absolute value will be added as additional fee, once\ + \ per charge session, paid by charge point owner.Will only be applied\ + \ to charge point owned by operator.Note: This uses the default currency\ + \ of the operator!" + format: double + example: 0.5 + roamingAdditionalFeePercentage: + required: + - "false" + type: integer + description: "Same as the additional fee percentage, but only applied to\ + \ roaming sessions." + format: int32 + nullable: true + example: 2 + roamingAdditionalFeeAbsolute: + required: + - "false" + type: number + description: "Same as the additional fee absolute, but only applied to roaming\ + \ sessions." + format: double + nullable: true + example: 0.5 + roamingAdditionalStartingFee: + required: + - "false" + type: number + description: "Same as the additional starting fee, but only applied to roaming\ + \ sessions." + format: double + nullable: true + example: 0.5 PlanServiceConfigTaxRefund: required: - additionalFeeAbsolute @@ -11813,6 +17312,13 @@ components: - priceIncludesVat type: object properties: + additionalFeeApplicationScope: + description: Type of charges to which custom additional fees are applied + nullable: true + example: all + allOf: + - $ref: "#/components/schemas/PlanCustomAdditionalFeeApplicationScope" + - {} additionalFeePercentage: required: - "true" @@ -11840,36 +17346,297 @@ components: priceIncludesVat: required: - "true" - type: boolean - description: Indicates whether the VAT is already included in the price - example: true - PlanServiceType: - type: string - enum: - - custom - - tax-refund - Price: + type: boolean + description: Indicates whether the VAT is already included in the price + example: true + PlanServiceType: + type: string + enum: + - custom + - tax-refund + Price: + required: + - start + type: object + properties: + start: + type: string + description: start + format: date-time + price: + type: number + description: price + nullable: true + PriceGroup: + required: + - appliedTo + - createdAt + - id + - masterPrice + - name + - tariffs + - type + type: object + properties: + id: + minimum: 0 + exclusiveMinimum: true + required: + - "true" + type: integer + description: Id of the price group + format: int64 + example: 522 + name: + required: + - "true" + type: string + description: Name of the price group + example: Public Price Group + default: + type: boolean + type: + description: Type of the price group + example: public + allOf: + - $ref: "#/components/schemas/PriceGroupType" + - {} + masterPrice: + description: The master price + allOf: + - $ref: "#/components/schemas/Pricing" + - {} + tariffs: + required: + - "true" + type: array + description: Tariffs of the price group + nullable: true + items: + $ref: "#/components/schemas/Pricing" + fees: + required: + - "false" + type: array + description: Fees of the price group + nullable: true + items: + $ref: "#/components/schemas/Pricing" + teamMemberCount: + required: + - "false" + type: integer + description: To how many team members the price group has been applied to + format: int32 + nullable: true + chargePointCount: + required: + - "false" + type: integer + description: To how many charge points the price group has been applied + to + format: int32 + nullable: true + appliedTo: + $ref: "#/components/schemas/PriceGroupAppliedTo" + createdAt: + required: + - "true" + type: string + description: When the price group was created + format: date-time + example: 2023-03-16T15:37:23Z + updatedAt: + required: + - "false" + type: string + description: When the price group was updated + format: date-time + nullable: true + example: 2023-03-16T15:37:23Z + PriceGroupAppliedTo: + required: + - chargePoints + - sites + - teamMembers + type: object + properties: + chargePoints: + required: + - "true" + type: array + description: Id's of the ChargePoints this Pricegroup has been applied to + items: + type: integer + format: int64 + sites: + required: + - "true" + type: array + description: Id's of the Sites this Pricegroup has been applied to + items: + type: integer + format: int64 + teamMembers: + required: + - "true" + type: array + description: Id's of the Team Members this Pricegroup has been applied to + items: + type: integer + format: int64 + PriceGroupTag: + required: + - createdAt + - name + type: object + properties: + id: + type: integer + description: The id for this tag. + format: int64 + example: null + name: + type: string + description: The name for this tag. + example: Energy + description: + type: string + description: The description for this tag. + nullable: true + example: Used to group `Energy` pricing elements + partnerExternalId: + type: string + description: "External Id of this entity, managed by you." + nullable: true + example: ACME-12345 + partnerCustomPayload: + type: array + description: "Custom JSON payload for this entity, managed by you." + nullable: true + items: + type: object + operator: + description: The operator to which this resource belongs to. + nullable: true + allOf: + - $ref: "#/components/schemas/Operator" + - {} + createdAt: + type: string + description: Creation date of this resource. + format: date-time + example: 2022-05-12T15:56:45.99Z + updatedAt: + type: string + description: Last update date of this resource. + format: date-time + nullable: true + example: 2022-05-12T16:56:45.99Z + PriceGroupType: + type: string + enum: + - public + - member + - sponsored + - cost + - roaming + - reimbursement + - other + PriceGroup_1: + required: + - name + type: object + properties: + id: + type: integer + description: Id of the price group + format: int64 + example: 1 + name: + type: string + description: Name of the price group + example: Standard Pricing + PriceSpecification: + required: + - specifications + type: object + properties: + specifications: + type: array + description: price specifications + items: + $ref: "#/components/schemas/Pair_String.BigDecimal_" + PricesForecast: + required: + - currency + - forecasts + - operator + - priceGroup + type: object + properties: + operator: + description: The operator to which this charge point and price group belongs + to + allOf: + - $ref: "#/components/schemas/Operator" + - {} + currency: + description: The currency applicable for this forecast + allOf: + - $ref: "#/components/schemas/Currency_17" + - {} + priceGroup: + description: The price group applicable for this forecast + allOf: + - $ref: "#/components/schemas/PriceGroup" + - {} + forecasts: + required: + - "true" + type: array + description: The compilation of entries composing this prices forecast + items: + $ref: "#/components/schemas/PricesForecastEntry" + PricesForecastEntry: required: - - start + - name + - pricePerKwh + - time type: object properties: - start: + time: + required: + - "true" type: string - description: start + description: "The time this forecasted price is applicable, forecast is\ + \ valid from time + 1 Hour" format: date-time - price: - type: number - description: price - nullable: true - PriceGroup: + example: 2023-11-29T18:00:00Z + pricePerKwh: + required: + - "true" + type: integer + description: The projected price per kWh + format: int64 + example: 5978 + name: + required: + - "true" + type: string + description: The human readable name for the forecast (includes the currency + information) + example: 0.60 DKK/kWh + Pricing: required: - - appliedTo - - createdAt + - dynamicPricing + - endAtFullyCharged - id - - masterPrice - - name - - tariffs + - master + - price - type + - updatedAt + - vat type: object properties: id: @@ -11878,468 +17645,513 @@ components: required: - "true" type: integer - description: Id of the price group + description: Id of the pricing format: int64 - example: 522 - name: + example: 1 + description: required: - - "true" + - "false" type: string - description: Name of the price group - example: Public Price Group - default: - type: boolean + description: Name of the pricing. It will be null when it's the master price + nullable: true + example: Starting Fee type: + description: Type of the pricing. `minute` is used for Minute fee. `min` + is used for the master price. + example: min allOf: - - $ref: '#/components/schemas/PriceGroupType' - - description: Type of the price group - example: public - masterPrice: - allOf: - - $ref: '#/components/schemas/Pricing' - - description: The master price - tariffs: + - $ref: "#/components/schemas/PricingType" + - {} + master: required: - "true" - type: array - description: Tariffs of the price group + type: boolean + description: If this is the master price (not a fee) + example: true + dynamicPricing: + required: + - "true" + type: boolean + description: If it's a dynamic price. It will be true if a `tariffId` is + present. + example: false + endAtFullyCharged: + required: + - "true" + type: boolean + description: Used by the Minute fee. True means it will stop charging the + fee when the charge is complete. False means it will stop charging the + fee when the cable is unplugged + example: false + vat: + required: + - "true" + type: boolean + description: "Used by Spot Price. True means it will add % of VAT on top\ + \ the price calculations
*Note*: `vat` rates differ from country to\ + \ country." + example: false + percentage: + type: number + description: Used by Spot Price. It will multiply the fallback price by + this percentage + format: float nullable: true - items: - $ref: '#/components/schemas/Pricing' - fees: + example: 10.2 + tariffId: required: - "false" - type: array - description: Fees of the price group + type: integer + description: The id of the selected Tariff + format: int64 nullable: true - items: - $ref: '#/components/schemas/Pricing' - teamMemberCount: + example: 5 + updatedAt: + required: + - "true" + type: string + description: When the pricing was last updated + format: date-time + example: 2023-03-16T15:37:23Z + applyAfterMinutes: required: - "false" type: integer - description: To how many team members the price group has been applied to + description: "Used by Charging, Minute and Idle Fees. After how many minutes\ + \ the fee should start being applied." format: int32 nullable: true - chargePointCount: + example: 30 + price: + description: The price of this Fee or Master price + allOf: + - $ref: "#/components/schemas/Money" + - {} + priceMin: + description: Used by spot price. The minimum that the raw spot price can + be. This will be used in calculations if spot price is lower than this + nullable: true + allOf: + - $ref: "#/components/schemas/Money" + - {} + priceMax: + description: Used by spot price. The maximum that the raw spot price can + be. This will be used in calculations if spot price is higher than this + nullable: true + allOf: + - $ref: "#/components/schemas/Money" + - {} + feePriceMax: + description: Used by Idle fee. The maximum the user will be charged for + the idle fee + nullable: true + allOf: + - $ref: "#/components/schemas/Money" + - {} + additional: required: - "false" - type: integer - description: To how many charge points the price group has been applied - to - format: int32 + type: array + description: Used by spot price. Additional absolute money or percentages + values to be added on top of the previous calculations nullable: true - appliedTo: - $ref: '#/components/schemas/PriceGroupAppliedTo' - createdAt: + items: + $ref: "#/components/schemas/AdditionalPricing" + from: required: - - "true" + - "false" type: string - description: When the price group was created + description: DateTime "from" time to which this pricing should apply from format: date-time + nullable: true example: 2023-03-16T15:37:23Z - updatedAt: + to: required: - "false" type: string - description: When the price group was updated + description: DateTime "to" time to which this pricing should apply to format: date-time nullable: true example: 2023-03-16T15:37:23Z - PriceGroupAppliedTo: - required: - - chargePoints - - sites - - teamMembers - type: object - properties: - chargePoints: - required: - - "true" - type: array - description: Id's of the ChargePoints this Pricegroup has been applied to - items: - type: integer - format: int64 - sites: - required: - - "true" - type: array - description: Id's of the Sites this Pricegroup has been applied to - items: - type: integer - format: int64 - teamMembers: + tagId: required: - - "true" - type: array - description: Id's of the Team Members this Pricegroup has been applied to - items: - type: integer - format: int64 - PriceGroupTag: + - "false" + type: integer + description: The id of the charge pricing tag for this pricing + format: int64 + nullable: true + example: 109 + PricingType: + type: string + enum: + - kwh + - min + - spot + - tariff + - starting + - charging + - idle + - minute + PublicChargePoint: required: - - createdAt - - name + - chargePointOperatorName + - evseId + - location type: object properties: id: type: integer - description: The id for this tag. + description: Id of this charge point + format: int64 + example: 1 + evseId: + type: string + description: The EVSE id for this charge point + example: DK*MON*E2 + name: + type: string + description: Name of the charge point + nullable: true + example: Monta CPH HQ + chargePointOperatorName: + type: string + description: The charge point operator name + nullable: false + example: Monta + location: + description: Location information for this charge point + allOf: + - $ref: "#/components/schemas/Location" + - {} + maxKw: + type: number + description: Max KW available at this charge point. + format: double + nullable: true + example: 150 + chargePointModelId: + type: integer + description: The ID of the charge point model for this charge point. format: int64 - name: + nullable: true + example: 42 + brandName: type: string - description: The name for this tag. - example: Energy - description: + description: Brand name for this charge point + nullable: true + example: Easee + modelName: type: string - description: The description for this tag. + description: Model name for this charge point nullable: true - example: Used to group `Energy` pricing elements - partnerExternalId: + example: Easee - Home + deletedAt: type: string - description: "External Id of this entity, managed by you." + description: Date this charge point was deleted + format: date-time nullable: true - example: ACME-12345 - partnerCustomPayload: - type: array - description: "Custom JSON payload for this entity, managed by you." + example: 2022-05-12T16:56:45.99Z + PublicTeam: + type: object + properties: + id: + type: integer + description: Id of the public team + format: int64 + example: 1 + publicName: + type: string + description: Public name of the team nullable: true - items: - type: object - operator: + example: Example Team + memberCount: + type: integer + description: Number of members in the team + format: int64 nullable: true - allOf: - - $ref: '#/components/schemas/Operator' - - description: The operator to which this resource belongs to. - createdAt: + example: 10 + PublicUser: + type: object + properties: + id: + type: integer + description: Id of the user + format: int64 + example: 1 + firstName: type: string - description: Creation date of this resource. - format: date-time - example: 2022-05-12T15:56:45.99Z - updatedAt: + description: First name of the user + nullable: true + example: John + lastName: type: string - description: Last update date of this resource. - format: date-time + description: Last name of the user nullable: true - example: 2022-05-12T16:56:45.99Z - PriceGroupType: - type: string - enum: - - public - - member - - sponsored - - cost - - roaming - - reimbursement - - other - PriceSpecification: + example: Doe + displayName: + type: string + description: Display name of the user + nullable: true + example: johndoe123 + PublicUser_1: required: - - specifications + - displayName + - id type: object properties: - specifications: - type: array - description: price specifications - items: - $ref: '#/components/schemas/Pair_String.BigDecimal_' - PricesForecast: + id: + required: + - "true" + type: integer + description: Id of the user + format: int64 + example: 10 + displayName: + required: + - "true" + type: string + description: Formatted name to be displayed + example: John Doe + PublicUser_3: required: - - currency - - forecasts - - operator - - priceGroup + - displayName + - id type: object properties: - operator: - allOf: - - $ref: '#/components/schemas/Operator' - - description: The operator to which this charge point and price group belongs - to - currency: - allOf: - - $ref: '#/components/schemas/Currency' - - description: The currency applicable for this forecast - priceGroup: - allOf: - - $ref: '#/components/schemas/PriceGroup' - - description: The price group applicable for this forecast - forecasts: + id: required: - "true" - type: array - description: The compilation of entries composing this prices forecast - items: - $ref: '#/components/schemas/PricesForecastEntry' - PricesForecastEntry: + type: integer + description: Id of the user + format: int64 + example: 10 + displayName: + required: + - "true" + type: string + description: Formatted name to be displayed + example: John Doe + ReasonDto: required: - - name - - pricePerKwh - - time + - id + - identifier + - priority + - reason + - type type: object properties: - time: + id: + required: + - "true" + type: integer + description: Id of the reason + format: int32 + example: 10 + identifier: required: - "true" type: string - description: "The time this forecasted price is applicable, forecast is\ - \ valid from time + 1 Hour" - format: date-time - example: 2023-11-29T18:00:00Z - pricePerKwh: + description: Identifier of the reason + reason: required: - "true" - type: integer - description: The projected price per kWh - format: int64 - example: 5978 - name: + type: string + description: Reason of the report + type: required: - "true" type: string - description: The human readable name for the forecast (includes the currency - information) - example: 0.60 DKK/kWh - Pricing: + description: Type of the report + priority: + required: + - "true" + type: string + description: Priority of the report + ReportDto: required: - - dynamicPricing - - endAtFullyCharged + - createdAt - id - - master - - price - - type - - updatedAt - - vat + - imageUrls + - operatorId + - relationId + - relationType + - state type: object properties: id: - minimum: 0 - exclusiveMinimum: true required: - "true" type: integer - description: Id of the pricing + description: Id of the report format: int64 - example: 1 - description: + example: 10 + reportedByUserId: required: - "false" - type: string - description: Name of the pricing. It will be null when it's the master price + type: integer + description: Id of the user who reported + format: int64 nullable: true - example: Starting Fee - type: - allOf: - - $ref: '#/components/schemas/PricingType' - - description: Type of the pricing. `minute` is used for Minute fee. `min` - is used for the master price. - example: min - master: + example: 10 + operatorId: required: - "true" - type: boolean - description: If this is the master price (not a fee) - example: true - dynamicPricing: + type: integer + description: Id of the operator related to the report + format: int64 + example: 10 + relationType: required: - "true" - type: boolean - description: If it's a dynamic price. It will be true if a `tariffId` is - present. - example: false - endAtFullyCharged: + type: string + description: Type of the relation + relationId: required: - "true" - type: boolean - description: Used by the Minute fee. True means it will stop charging the - fee when the charge is complete. False means it will stop charging the - fee when the cable is unplugged - example: false - vat: + type: integer + description: Id of the relation + format: int64 + example: 10 + body: + required: + - "false" + type: string + description: Body of the report + nullable: true + example: available but can not start + state: required: - "true" - type: boolean - description: "Used by Spot Price. True means it will add % of VAT on top\ - \ the price calculations
*Note*: `vat` rates differ from country to\ - \ country." - example: false - percentage: + type: string + description: State of the report + reason: + description: Reason of the report + nullable: true + allOf: + - $ref: "#/components/schemas/ReasonDto" + - {} + source: required: - "false" - type: number - description: Used by Spot Price. It will multiply the fallback price by - this percentage - format: float + type: string + description: Source of the report nullable: true - example: 10.2 - default: 100 - tariffId: + imageUrls: + required: + - "true" + type: array + description: List of image URLs + example: + - https://monta.imgix.net/reports/example-image-1.png + - https://monta.imgix.net/reports/example-image-2.png + items: + type: string + assignedToOperatorId: required: - "false" type: integer - description: The id of the selected Tariff + description: Id of the operator assigned to the report format: int64 nullable: true - example: 5 - updatedAt: - required: - - "true" - type: string - description: When the pricing was last updated - format: date-time - example: 2023-03-16T15:37:23Z - applyAfterMinutes: + example: 10 + assignedToUserId: required: - "false" type: integer - description: "Used by Charging, Minute and Idle Fees. After how many minutes\ - \ the fee should start being applied." - format: int32 - nullable: true - example: 30 - price: - allOf: - - $ref: '#/components/schemas/Money' - - description: The price of this Fee or Master price - priceMin: + description: Id of the user assigned to the report + format: int64 nullable: true - allOf: - - $ref: '#/components/schemas/Money' - - description: Used by spot price. The minimum that the raw spot price can - be. This will be used in calculations if spot price is lower than this - priceMax: + example: 10 + resolvedByUserId: + required: + - "false" + type: integer + description: Id of the user who resolved the report + format: int64 nullable: true - allOf: - - $ref: '#/components/schemas/Money' - - description: Used by spot price. The maximum that the raw spot price can - be. This will be used in calculations if spot price is higher than this - feePriceMax: + example: 10 + operatorNote: + required: + - "false" + type: string + description: Note from the operator nullable: true - allOf: - - $ref: '#/components/schemas/Money' - - description: Used by Idle fee. The maximum the user will be charged for - the idle fee - additional: + example: The charge point is not working + adminNote: required: - "false" - type: array - description: Used by spot price. Additional absolute money or percentages - values to be added on top of the previous calculations + type: string + description: Note from the admin nullable: true - items: - $ref: '#/components/schemas/AdditionalPricing' - from: + example: The charge point is not working + userNote: required: - "false" type: string - description: DateTime "from" time to which this pricing should apply from - format: date-time + description: Note from the user nullable: true - example: 2023-03-16T15:37:23Z - to: + example: The charge point is not working + resolvedAt: required: - "false" type: string - description: DateTime "to" time to which this pricing should apply to + description: Time when the report was resolved format: date-time nullable: true - example: 2023-03-16T15:37:23Z - tagId: + example: 2023-02-06T11:00:00Z + escalatedAt: required: - "false" - type: integer - description: The id of the charge pricing tag for this pricing - format: int64 - nullable: true - example: 109 - PricingType: - type: string - enum: - - kwh - - min - - spot - - tariff - - starting - - charging - - idle - - minute - PublicChargePoint: - required: - - chargePointOperatorName - - evseId - - location - type: object - properties: - id: - type: integer - description: Id of this charge point - format: int64 - example: 1 - evseId: - type: string - description: The EVSE id for this charge point - example: DK*MON*E2 - name: type: string - description: Name of the charge point + description: Time when the report was escalated + format: date-time nullable: true - example: Monta CPH HQ - chargePointOperatorName: + example: 2023-02-06T10:00:00Z + assignedAt: + required: + - "false" type: string - description: The charge point operator name - nullable: false - example: Monta - location: - allOf: - - $ref: '#/components/schemas/Location' - - description: Location information for this charge point - maxKw: - type: number - description: Max KW available at this charge point. - format: double - nullable: true - example: 150 - chargePointModelId: - type: integer - description: The ID of the charge point model for this charge point. - format: int64 + description: Time when the report was assigned + format: date-time nullable: true - example: 42 - brandName: + example: 2023-02-06T09:00:00Z + createdAt: + required: + - "true" type: string - description: Brand name for this charge point - nullable: true - example: Easee - modelName: + description: Time when the report was created + format: date-time + example: 2023-02-06T08:00:00Z + updatedAt: + required: + - "false" type: string - description: Model name for this charge point + description: Time when the report was updated + format: date-time nullable: true - example: Easee - Home + example: 2023-02-06T11:00:00Z deletedAt: + required: + - "false" type: string - description: Date this charge point was deleted + description: Time when the report was deleted format: date-time nullable: true - example: 2022-05-12T16:56:45.99Z - PublicUser: - required: - - displayName - - id + example: 2023-02-06T12:00:00Z + SimCard: type: object properties: - id: - required: - - "true" - type: integer - description: Id of the user - format: int64 - example: 10 - displayName: - required: - - "true" + imsi: type: string - description: Formatted name to be displayed - example: John Doe + description: imsi (International Mobile Subscriber Identity) for the SIM + card + nullable: true + example: "310150123456789" + iccid: + type: string + description: iccid (Integrated Circuit Card Identifier) for the SIM card + nullable: true + example: "8931501234567890123" SimpleTeamMemberDto: required: - id @@ -12411,10 +18223,11 @@ components: description: Name of the site example: Monta CPH HQ operator: + description: Operator of this charging site nullable: true allOf: - - $ref: '#/components/schemas/Operator' - - description: Operator of this charging site + - $ref: "#/components/schemas/Operator" + - {} createdAt: type: string description: Creation date of this charging site @@ -12482,15 +18295,16 @@ components: nullable: true example: In order to access this site enter 0000 as code at the gate. location: + description: Location information for this site allOf: - - $ref: '#/components/schemas/Location' - - description: Location information for this site + - $ref: "#/components/schemas/Location" + - {} connectors: type: array description: "List of supported connector types at this site (e.g. type-2,\ \ ccs, ...)" items: - $ref: '#/components/schemas/ChargePointConnector' + $ref: "#/components/schemas/ChargePointConnector" Slice_TariffRecurringPeriodDto_: required: - content @@ -12500,9 +18314,9 @@ components: content: type: array items: - $ref: '#/components/schemas/TariffRecurringPeriod' + $ref: "#/components/schemas/TariffRecurringPeriod" pageable: - $ref: '#/components/schemas/Pageable' + $ref: "#/components/schemas/Pageable" pageNumber: type: integer format: int32 @@ -12525,7 +18339,7 @@ components: orderBy: type: array items: - $ref: '#/components/schemas/Sort.Order' + $ref: "#/components/schemas/Sort.Order" Sort.Order: required: - direction @@ -12536,7 +18350,7 @@ components: ignoreCase: type: boolean direction: - $ref: '#/components/schemas/Sort.Order.Direction' + $ref: "#/components/schemas/Sort.Order.Direction" property: type: string ascending: @@ -12579,23 +18393,26 @@ components: format: int64 example: 1 payout: + description: The payout frequency for this sponsored charge point + example: realtime allOf: - - $ref: '#/components/schemas/SponsoredChargePointPayoutType' - - description: The payout frequency for this sponsored charge point - example: realtime + - $ref: "#/components/schemas/SponsoredChargePointPayoutType" + - {} payForSubscriptions: type: boolean description: Indicates the company pays for the subscriptions example: true operator: + description: Operator of this sponsored charge point nullable: true allOf: - - $ref: '#/components/schemas/Operator' - - description: Operator of this sponsored charge point + - $ref: "#/components/schemas/Operator" + - {} chargePoint: + description: The charge point being sponsored allOf: - - $ref: '#/components/schemas/SponsoredChargePointData' - - description: The charge point being sponsored + - $ref: "#/components/schemas/SponsoredChargePointData" + - {} acceptedAt: type: string description: Date the sponsorshi was accepted @@ -12636,19 +18453,22 @@ components: nullable: true example: Monta CPH HQ user: + description: The user (owner) of this charge point nullable: true allOf: - - $ref: '#/components/schemas/PublicUser' - - description: The user (owner) of this charge point + - $ref: "#/components/schemas/PublicUser_1" + - {} sponsoredPriceGroup: + description: The sponsored price group of this charge point nullable: true allOf: - - $ref: '#/components/schemas/PriceGroup' - - description: The sponsored price group of this charge point + - $ref: "#/components/schemas/PriceGroup" + - {} location: + description: Location information for this charge point allOf: - - $ref: '#/components/schemas/Location' - - description: Location information for this charge point + - $ref: "#/components/schemas/Location" + - {} serialNumber: type: string description: Serial number for this charge point @@ -12725,10 +18545,11 @@ components: type: object properties: type: + description: The type of this metadata entry + example: spot-price-additional-percentage-metadata allOf: - - $ref: '#/components/schemas/ComponentMetadataTypeDto' - - description: The type of this metadata entry - example: spot-price-additional-percentage-metadata + - $ref: "#/components/schemas/ComponentMetadataTypeDto" + - {} price: type: integer description: The additional price on top of the spot price metadata entry @@ -12749,10 +18570,11 @@ components: type: object properties: type: + description: The type of this metadata entry + example: spot-price-additional-price-metadata allOf: - - $ref: '#/components/schemas/ComponentMetadataTypeDto' - - description: The type of this metadata entry - example: spot-price-additional-price-metadata + - $ref: "#/components/schemas/ComponentMetadataTypeDto" + - {} kwh: required: - "true" @@ -12772,10 +18594,11 @@ components: type: object properties: type: + description: The type of this metadata entry + example: spot-price-metadata allOf: - - $ref: '#/components/schemas/ComponentMetadataTypeDto' - - description: The type of this metadata entry - example: spot-price-metadata + - $ref: "#/components/schemas/ComponentMetadataTypeDto" + - {} kwh: type: number description: The kwh for this metadata entry @@ -12817,6 +18640,7 @@ components: \ with `socLimit`, in this case the first limit to hit will stop the charge" format: double nullable: true + example: 20 socLimit: maximum: 100 minimum: 1 @@ -12826,6 +18650,16 @@ components: \ with `kwhLimit`, in this case the first limit to hit will stop the charge" format: double nullable: true + example: null + priceLimit: + minimum: 1 + type: number + description: "The charge price limit, meaning the charge will stop once\ + \ the price limit is reached.
*Note*: `priceLimit` will be in the\ + \ currency of the charge point." + format: double + nullable: true + example: 12.5 priceGroupId: minimum: 0 exclusiveMinimum: true @@ -12836,16 +18670,19 @@ components: nullable: true example: 42 genericPaymentSession: + description: "For Partners who want to start charging from payment terminals,\ + \ kiosks etc. Used to link charge transaction against your billing and\ + \ to allow users retrieving receipts via receipt.monta.com by using date\ + \ and `genericPaymentSession.externalId`or `genericPaymentSession.cardLast4`." nullable: true allOf: - - $ref: '#/components/schemas/GenericPaymentSession' - - description: "For Partners who want to start charging from payment terminals,\ - \ kiosks etc. Used to link charge transaction against your billing and\ - \ to allow users retrieving receipts via receipt.monta.com by using\ - \ date and `genericPaymentSession.externalId`or `genericPaymentSession.cardLast4`." + - $ref: "#/components/schemas/GenericPaymentSession" + - {} partnerExternalId: type: string - description: "External Id of this entity, managed by you." + description: "External Id of this entity, managed by you.
*Note*: How\ + \ this field is used is up to the partner, but we highly recommend using\ + \ a unique `partnerExternalId` for each `charge`." nullable: true example: ACME-12345 partnerCustomPayload: @@ -12871,6 +18708,32 @@ components: enum: - charge-point - vehicle + States: + required: + - duration + - percentage + - state + type: object + properties: + state: + required: + - "true" + type: string + description: State of the system or charge point + example: operational + percentage: + required: + - "true" + type: number + description: Percentage of the time spent in this state + example: 75 + duration: + required: + - "true" + type: integer + description: Duration in this state (in seconds) + format: int64 + example: 3600 Subscription: required: - createdAt @@ -12885,10 +18748,11 @@ components: format: int64 example: 1 state: + description: State of the subscription + example: active allOf: - - $ref: '#/components/schemas/SubscriptionState' - - description: State of the subscription - example: active + - $ref: "#/components/schemas/SubscriptionState" + - {} nextPurchaseAt: type: string description: Date of next purchase @@ -12948,21 +18812,23 @@ components: format: int64 example: 1 customerType: + description: Customer type + example: charge-point allOf: - - $ref: '#/components/schemas/SubscriptionCustomerType' - - description: Customer type - example: charge-point + - $ref: "#/components/schemas/SubscriptionCustomerType" + - {} planId: type: integer description: Plan id format: int64 example: 42 serviceConfig: + description: "Subscription configuration, based on the plans serviceType.Currently\ + \ you can configure tax-refund subscriptions only." nullable: true allOf: - - $ref: '#/components/schemas/SubscriptionServiceConfig' - - description: "Subscription configuration, based on the plans serviceType.Currently\ - \ you can configure tax-refund subscriptions only." + - $ref: "#/components/schemas/SubscriptionServiceConfig" + - {} createdAt: type: string description: Subscription creation date @@ -12983,13 +18849,19 @@ components: format: date-time nullable: true example: 2023-05-12T15:56:45.99Z + SubscriptionCustomAdditionalFeeApplicationScope: + type: string + enum: + - all + - paid SubscriptionCustomerType: type: string + description: Enumerate the various subscription customer types enum: - - team - - charge-point - - operator - - other + - TEAM + - CHARGE_POINT + - OPERATOR + - OTHER SubscriptionPurchase: required: - createdAt @@ -13009,10 +18881,11 @@ components: nullable: true example: "1" type: + description: The type of this subscription purchase + example: period allOf: - - $ref: '#/components/schemas/SubscriptionPurchaseTypeDto' - - description: The type of this subscription purchase - example: period + - $ref: "#/components/schemas/SubscriptionPurchaseTypeDto" + - {} discountPercentage: type: number description: The discount percentage applied to this purchase @@ -13039,13 +18912,15 @@ components: format: double example: 25 currency: + description: The currency for this purchase allOf: - - $ref: '#/components/schemas/Currency' - - description: The currency for this purchase + - $ref: "#/components/schemas/Currency_3" + - {} subscription: + description: The subscription this purchase refers to allOf: - - $ref: '#/components/schemas/Subscription' - - description: The subscription this purchase refers to + - $ref: "#/components/schemas/Subscription" + - {} createdAt: type: string description: Creation date of this subscription purchase @@ -13073,7 +18948,84 @@ components: SubscriptionServiceConfig: type: object anyOf: - - $ref: '#/components/schemas/SubscriptionServiceConfigTaxRefund' + - $ref: "#/components/schemas/SubscriptionServiceConfigTaxRefund" + - $ref: "#/components/schemas/SubscriptionServiceConfigCustom" + SubscriptionServiceConfigCustom: + required: + - additionalFeeAbsolute + - additionalFeePercentage + - additionalStartingFee + - serviceType + - subscriptionAdditionalFeeApplicationScope + type: object + properties: + serviceType: + description: "Plan service type, custom or tax-refund" + example: custom + allOf: + - $ref: "#/components/schemas/PlanServiceType" + - {} + subscriptionAdditionalFeeApplicationScope: + description: Amount to pay out per kWh + nullable: true + example: "1.29" + allOf: + - $ref: "#/components/schemas/SubscriptionCustomAdditionalFeeApplicationScope" + - {} + additionalFeePercentage: + required: + - "true" + type: integer + description: "This percentage will be added as additional fee, paid by charge\ + \ point owner.Will only be applied to charge point owned by operator." + format: int32 + example: 2 + additionalFeeAbsolute: + required: + - "true" + type: number + description: "This absolute value will be added as additional fee, paid\ + \ by charge point owner.Will only be applied to charge point owned by\ + \ operator.Note: This uses the default currency of the operator!" + format: double + example: 0.5 + additionalStartingFee: + required: + - "true" + type: number + description: "This absolute value will be added as additional fee, once\ + \ per charge session, paid by charge point owner.Will only be applied\ + \ to charge point owned by operator.Note: This uses the default currency\ + \ of the operator!" + format: double + example: 0.5 + roamingAdditionalFeePercentage: + required: + - "false" + type: integer + description: "Same as the additional fee percentage, but only applied to\ + \ roaming sessions." + format: int32 + nullable: true + example: 2 + roamingAdditionalFeeAbsolute: + required: + - "false" + type: number + description: "Same as the additional fee absolute, but only applied to roaming\ + \ sessions." + format: double + nullable: true + example: 0.5 + roamingAdditionalStartingFee: + required: + - "false" + type: number + description: "Same as the additional starting fee, but only applied to roaming\ + \ sessions." + format: double + nullable: true + example: 0.5 SubscriptionServiceConfigTaxRefund: required: - payoutPerKwh @@ -13082,10 +19034,11 @@ components: type: object properties: serviceType: + description: "Plan service type, custom or tax-refund" + example: tax-refund allOf: - - $ref: '#/components/schemas/PlanServiceType' - - description: "Service of the Plan, custom or tax-refund" - example: tax-refund + - $ref: "#/components/schemas/PlanServiceType" + - {} payoutPerKwh: required: - "true" @@ -13113,10 +19066,11 @@ components: type: object properties: type: + description: The type of this metadata entry + example: tariff-metadata allOf: - - $ref: '#/components/schemas/ComponentMetadataTypeDto' - - description: The type of this metadata entry - example: tariff-metadata + - $ref: "#/components/schemas/ComponentMetadataTypeDto" + - {} tariffId: type: integer description: The tariff id for this metadata entry @@ -13220,14 +19174,17 @@ components: zipCodes: type: array description: Zip codes of the tariff - example: "[5610, 5960]" + example: + - 5610 + - 5960 items: type: string tariffType: + description: Type of the tariff + example: WEEKLY allOf: - - $ref: '#/components/schemas/TariffType' - - description: Type of the tariff - example: WEEKLY + - $ref: "#/components/schemas/TariffType" + - {} active: type: boolean description: Indicates if the Tariff is active or not @@ -13241,11 +19198,12 @@ components: description: Area of the tariff example: Jylland customerType: + description: Customer type of the tariff nullable: true + example: B_HIGH allOf: - - $ref: '#/components/schemas/TariffCustomerType' - - description: Customer type of the tariff - example: B_HIGH + - $ref: "#/components/schemas/TariffCustomerType" + - {} createdAt: type: string description: Creation date of the tariff @@ -13283,6 +19241,45 @@ components: type: integer description: tariff id format: int64 + TariffPeriodGroup_1: + required: + - activeFrom + - activeTo + - description + type: object + properties: + activeFrom: + type: string + description: tariff period group active from date + format: date + activeTo: + type: string + description: tariff period group active to date + format: date + description: + type: string + description: tariff period group description + tariffId: + type: integer + description: tariff id + format: int64 + TariffPeriodGroup_2: + type: object + properties: + activeFrom: + type: string + description: tariff period group active from date + format: date + nullable: true + activeTo: + type: string + description: tariff period group active to date + format: date + nullable: true + description: + type: string + description: tariff period group description + nullable: true TariffRecurringPeriod: required: - dayOfWeek @@ -13298,14 +19295,16 @@ components: description: id of the tariff format: int64 dayOfWeek: + description: day of the period allOf: - - $ref: '#/components/schemas/DayOfWeek' - - description: day of the period + - $ref: "#/components/schemas/DayOfWeek" + - {} endDayOfWeek: + description: End day of the period nullable: true allOf: - - $ref: '#/components/schemas/DayOfWeek' - - description: End day of the period + - $ref: "#/components/schemas/DayOfWeek" + - {} start: type: integer description: starting hour of the period @@ -13342,17 +19341,18 @@ components: format: int64 example: 1 dayOfWeek: + description: Capitalized name of the day of the week + example: MONDAY allOf: - - $ref: '#/components/schemas/DayOfWeek' - - description: Capitalized name of the day of the week - example: MONDAY + - $ref: "#/components/schemas/DayOfWeek" + - {} endDayOfWeek: + description: Capitalized name of the day of the week that the price is for nullable: true + example: FRIDAY allOf: - - $ref: '#/components/schemas/DayOfWeek' - - description: Capitalized name of the day of the week that the price is - for - example: FRIDAY + - $ref: "#/components/schemas/DayOfWeek" + - {} startHour: required: - "true" @@ -13377,17 +19377,19 @@ components: type: object properties: dayOfWeek: + description: Capitalized name of the day of the week nullable: true + example: MONDAY allOf: - - $ref: '#/components/schemas/DayOfWeek' - - description: Capitalized name of the day of the week - example: MONDAY + - $ref: "#/components/schemas/DayOfWeek" + - {} endDayOfWeek: + description: Capitalized name of the end day of the week nullable: true + example: FRIDAY allOf: - - $ref: '#/components/schemas/DayOfWeek' - - description: Capitalized name of the end day of the week - example: FRIDAY + - $ref: "#/components/schemas/DayOfWeek" + - {} startHour: required: - "false" @@ -13432,9 +19434,15 @@ components: format: double example: 13.77 type: + description: The type of this metadata allOf: - - $ref: '#/components/schemas/MetadataTypeDto' - - description: The type of this metadata + - $ref: "#/components/schemas/MetadataTypeDto" + - {} + chargeId: + type: integer + description: The reference to chargeId for the tax refund + format: int64 + nullable: true Team: required: - address @@ -13486,18 +19494,21 @@ components: nullable: true example: DE123456789 operator: + description: The operator to this team is associated nullable: true allOf: - - $ref: '#/components/schemas/Operator' - - description: The operator to this team is associated + - $ref: "#/components/schemas/Operator" + - {} address: + description: The address where the team is located allOf: - - $ref: '#/components/schemas/TeamDto.TeamAddressDto' - - description: The address where the team is located + - $ref: "#/components/schemas/TeamDto.TeamAddressDto" + - {} currency: + description: The currency assigned for this team allOf: - - $ref: '#/components/schemas/Currency' - - description: The currency assigned for this team + - $ref: "#/components/schemas/Currency_7" + - {} type: type: string description: Type of the team @@ -13506,6 +19517,12 @@ components: - private - professional - operator + category: + description: Category of the team + nullable: true + allOf: + - $ref: "#/components/schemas/TeamDto.TeamCategoryDto" + - {} operatorId: type: integer description: "Deprecated (will be removed by 01.04.24), use `operator` field\ @@ -13520,6 +19537,21 @@ components: description: Id of the user that owns this team format: int64 example: 1 + isFrozen: + type: boolean + description: Whether the team is frozen or not + example: false + frozenReason: + type: string + description: Team freezing reason + nullable: true + example: removed team + frozenAt: + type: string + description: Frozen date of this team + format: date-time + nullable: true + example: 2022-05-12T16:56:45.99Z blockedAt: type: string description: Blocked date of this team @@ -13554,7 +19586,7 @@ components: type: string description: Second line of address nullable: true - example: København + example: København address3: type: string description: Third line of address @@ -13575,20 +19607,24 @@ components: description: The address country format: int64 example: 1 - TeamMemberAccess: - type: string - description: "definitions: \n* `all` - Indicates the team member has access\ - \ all the team's charge points. \n* `selected` - Indicates the team member\ - \ has only access to the selected charge points. \n* `other` - Fallback value,\ - \ Indicates a new type was added but is not mapped/unknown on this API yet.\ - \ \n" - enum: - - all - - selected - - other - TeamMemberDto: + TeamDto.TeamCategoryDto: + required: + - identifier + - name + type: object + properties: + identifier: + type: string + description: Category Identifier + example: cpo + name: + type: string + description: Category name + example: Charge Point Operator + TeamMember: required: - access + - canPayForChargesCountryIds - chargePointIds - id - role @@ -13599,9 +19635,10 @@ components: id: required: - "true" - type: string + type: integer description: Id of the team member - example: "1" + format: int64 + example: 1 teamId: type: integer description: Team id of team member @@ -13614,10 +19651,11 @@ components: nullable: true example: Casper Rasmussen operator: + description: Operator of this team member nullable: true allOf: - - $ref: '#/components/schemas/Operator' - - description: Operator of this team member + - $ref: "#/components/schemas/Operator" + - {} partnerExternalTeamId: type: string description: The partner external id for the team @@ -13631,21 +19669,24 @@ components: nullable: true example: 1 role: + description: Role of the this member within the team + example: admin allOf: - - $ref: '#/components/schemas/TeamMemberRole' - - description: Role of the this member within the team - example: admin + - $ref: "#/components/schemas/TeamMemberRole" + - {} access: + description: Indicates if the user has access to all charge points or only + to selected charge points + example: all allOf: - - $ref: '#/components/schemas/TeamMemberAccess' - - description: Indicates if the user has access to all charge points or - only to selected charge points - example: all + - $ref: "#/components/schemas/TeamMemberAccess_1" + - {} state: + description: State of the invitation + example: accepted allOf: - - $ref: '#/components/schemas/TeamMemberState' - - description: State of the invitation - example: accepted + - $ref: "#/components/schemas/TeamMemberState_1" + - {} note: type: string description: Note for team member @@ -13701,6 +19742,24 @@ components: format: int64 nullable: true example: 1 + costGroupId: + type: integer + description: The cost group for this team member + format: int64 + nullable: true + example: 1 + teamMemberProfileId: + type: integer + description: The team member profile id to apply to this team member + format: int64 + nullable: true + example: 1 + canConfigureChargePoints: + type: boolean + description: Indicates if the team member access to pay with team wallet + when charging + example: false + default: false canPayWithTeamWallet: type: boolean description: Indicates if the team member access to pay with team wallet @@ -13725,8 +19784,18 @@ components: settings example: false default: false + canPayForChargesCountryIds: + type: array + description: List of country ids for which the team member can pay for charges + example: + - 1 + - 2 + - 3 + items: + type: integer + format: int32 teamWalletChargePaymentType: - $ref: '#/components/schemas/TeamWalletChargePaymentType' + $ref: "#/components/schemas/TeamWalletChargePaymentType" partnerExternalId: type: string description: "External Id of this entity, managed by you." @@ -13738,6 +19807,136 @@ components: nullable: true items: type: object + TeamMemberAccess: + type: string + enum: + - all + - selected + TeamMemberAccess_1: + type: string + description: "definitions: \n* `all` - Indicates the team member has access\ + \ all the team's charge points. \n* `selected` - Indicates the team member\ + \ has only access to the selected charge points. \n* `other` - Fallback value,\ + \ Indicates a new type was added but is not mapped/unknown on this API yet.\ + \ \n" + enum: + - all + - selected + - other + TeamMemberProfile: + required: + - id + - name + - role + - teamWalletChargePaymentType + type: object + properties: + id: + required: + - "true" + type: integer + description: Id of the team member profile + format: int64 + example: 1 + teamId: + type: integer + description: Team id of team member profile + format: int64 + example: 42 + name: + type: string + description: The team member profile name + example: Example profile 1 + description: + type: string + description: The team member profile description + nullable: true + example: description + role: + description: Role of the this team member profile + example: admin + allOf: + - $ref: "#/components/schemas/TeamMemberRole" + - {} + priceGroupId: + type: integer + description: The price group for this team member profile + format: int64 + nullable: true + example: 1 + costGroupId: + type: integer + description: The cost group for this team member profile + format: int64 + nullable: true + example: 1 + canPayWithTeamWallet: + type: boolean + description: Indicates if the team member profile access to pay with team + wallet when charging + example: false + default: false + canManageTeamWallet: + type: boolean + description: Indicates if team member profile has access to withdraw and + deposit from your team wallet to your bank account + example: false + default: false + canRequestSponsoring: + type: boolean + description: Indicates if the team member profile is allowed to request + sponsoring from this team for their charge point + example: false + default: false + canManageTeamMembers: + type: boolean + description: Indicates that the team member profile can view and manage + other members settings + example: false + default: false + canConfigureChargePoints: + type: boolean + description: Indicates that the team member profile can configure charge + points + example: false + default: false + teamWalletChargePaymentType: + $ref: "#/components/schemas/TeamWalletChargePaymentType" + canPayForChargesCountryIds: + type: array + description: List of country ids for which the team member can pay for charges + nullable: true + example: + - 1 + - 2 + - 3 + items: + type: integer + format: int32 + operator: + description: Operator of this team member + nullable: true + allOf: + - $ref: "#/components/schemas/Operator" + - {} + createdAt: + type: string + description: Date the team member profile was created + format: date-time + nullable: true + example: 2022-05-12T15:56:45.99Z + updatedAt: + type: string + description: Date the team member profile was updated + format: date-time + nullable: true + example: 2022-05-12T16:56:45.99Z + deletedAt: + type: string + description: Date the team member profile was deleted + format: date-time + nullable: true + example: 2022-05-12T16:56:45.99Z TeamMemberRole: type: string enum: @@ -13745,6 +19944,25 @@ components: - user - other TeamMemberState: + type: string + enum: + - requested + - invited + - accepted + - rejected_at + - blocked + - expired + TeamMemberState_1: + type: string + enum: + - requested + - invited + - rejected + - accepted + - blocked + - expired + - other + TeamMemberState_3: type: string enum: - requested @@ -13757,8 +19975,8 @@ components: TeamOrOperator: type: object anyOf: - - $ref: '#/components/schemas/Operator' - - $ref: '#/components/schemas/PayingTeam' + - $ref: "#/components/schemas/Operator" + - $ref: "#/components/schemas/PayingTeam" TeamType.Creatable: type: string enum: @@ -13775,6 +19993,26 @@ components: - all - none default: none + TimePeriod: + required: + - dailyPerformance + - date + type: object + properties: + date: + required: + - "true" + type: string + description: Date for the statistics + format: date-time + example: 2024-03-30T00:00:00Z + dailyPerformance: + required: + - "true" + type: array + description: Performance metrics for the day + items: + $ref: "#/components/schemas/Performance" Token: required: - accessToken @@ -13876,15 +20114,18 @@ components: type: array description: Zip codes where this tariff is applicable nullable: true - example: "[\"2200\", \"2100\"]" + example: + - "2200" + - "2100" items: type: string tariffType: + description: Dynamic or weekly nullable: true + example: WEEKLY allOf: - - $ref: '#/components/schemas/TariffType' - - description: Dynamic or weekly - example: WEEKLY + - $ref: "#/components/schemas/TariffType" + - {} active: required: - "true" @@ -13904,13 +20145,117 @@ components: description: Human description of the area the tariff is active in example: Fyn customerType: + description: What kind of customer types are the tariff for? + nullable: true + example: c_customer + allOf: + - $ref: "#/components/schemas/TariffCustomerType" + - {} + UpdateTeamStateDto: + type: object + properties: + reason: + type: string + description: Team freezing reason + nullable: true + example: removed team + User: + required: + - id + type: object + properties: + id: + required: + - "true" + type: integer + description: Id of the user + format: int64 + example: 10 + firstName: + required: + - "false" + type: string + description: First name of the user + nullable: true + example: John + lastName: + required: + - "false" + type: string + description: Last name of the user + nullable: true + example: Doe + email: + required: + - "false" + type: string + description: Email of the user + nullable: true + example: john.doe@example.com + phone: + required: + - "false" + type: string + description: Phone number of the user + nullable: true + example: "+1234567890" + profileImageUrl: + required: + - "false" + type: string + description: URL of the profile image + nullable: true + example: https://example.com/profile.jpg + address: + description: Address of the user nullable: true allOf: - - $ref: '#/components/schemas/TariffCustomerType' - - description: What kind of customer types are the tariff for? - example: c_customer + - $ref: "#/components/schemas/Address" + - {} + language: + required: + - "false" + type: string + description: Preferred language of the user + nullable: true + example: en + termsReadAt: + required: + - "false" + type: string + description: Timestamp when the user read the terms + format: date-time + nullable: true + example: 2023-06-21T15:03:14Z + createdAt: + required: + - "false" + type: string + description: Timestamp when the user was created + format: date-time + nullable: true + example: 2023-06-21T15:03:14Z + updatedAt: + required: + - "false" + type: string + description: Timestamp when the user was last updated + format: date-time + nullable: true + example: 2023-06-21T15:03:14Z + deletedAt: + required: + - "false" + type: string + description: Timestamp when the user was deleted + format: date-time + nullable: true + example: 2023-06-21T15:03:14Z VisibilityType: type: string + description: "definitions: \n* `private` - Indicates the charge point access\ + \ is private, only available to users from operator umbrella. \n* `public`\ + \ - Indicates the charge point access is public. \n" enum: - private - public @@ -13953,10 +20298,11 @@ components: description: CountryId of this wallet. format: int64 balance: + description: "Balance of this wallet, if available (not in list endpoints)." nullable: true allOf: - - $ref: '#/components/schemas/WalletDto.BalanceDto' - - description: "Balance of this wallet, if available (not in list endpoints)." + - $ref: "#/components/schemas/WalletDto.BalanceDto" + - {} WalletDto.BalanceDto: type: object properties: @@ -14001,20 +20347,22 @@ components: format: double example: 2.75 fromCurrency: + description: Currency for `fromAmount`. allOf: - - $ref: '#/components/schemas/Currency' - - description: Currency for `fromAmount`. + - $ref: "#/components/schemas/Currency_13" + - {} fromType: type: string description: "Type of sender: operator, team" nullable: true example: team from: + description: "Type of sender: operator, team" nullable: true + example: team allOf: - - $ref: '#/components/schemas/TeamOrOperator' - - description: "Type of sender: operator, team" - example: team + - $ref: "#/components/schemas/TeamOrOperator" + - {} fromWalletId: required: - "false" @@ -14040,20 +20388,22 @@ components: format: double example: 2.75 toCurrency: + description: Currency used for `toAmount`. allOf: - - $ref: '#/components/schemas/Currency' - - description: Currency used for `toAmount`. + - $ref: "#/components/schemas/Currency_14" + - {} toType: type: string description: "Type of receiver: operator, team" nullable: true example: operator to: + description: "Type of sender: operator, team" nullable: true + example: team allOf: - - $ref: '#/components/schemas/TeamOrOperator' - - description: "Type of sender: operator, team" - example: team + - $ref: "#/components/schemas/TeamOrOperator" + - {} toWalletId: required: - "false" @@ -14081,23 +20431,32 @@ components: format: date-time nullable: true example: 2022-04-22T09:47:05Z + completedAt: + required: + - "false" + type: string + description: Completion date of transaction + format: date-time + nullable: true + example: 2022-04-22T09:47:05Z referenceId: type: string description: Reference id of this transaction. e.g the charge id nullable: true example: referenceId referenceType: + description: Reference type of this transaction. nullable: true + example: CHARGE allOf: - - $ref: '#/components/schemas/WalletTransactionReferenceType' - - description: Reference type of this transaction. - example: CHARGE + - $ref: "#/components/schemas/WalletTransactionReferenceType" + - {} group: + description: Transaction group of this transaction + example: withdraw allOf: - - $ref: '#/components/schemas/WalletTransactionGroup' + - $ref: "#/components/schemas/WalletTransactionGroup" - type: string - description: Transaction group of this transaction - example: withdraw kind: type: string description: "\n Kind of this transaction, ie 'charge-sponsored'.\n\ @@ -14110,11 +20469,11 @@ components: format: double example: 25 state: + description: Transaction state of this transaction + example: complete allOf: - - $ref: '#/components/schemas/WalletTransactionState' + - $ref: "#/components/schemas/WalletTransactionState" - type: string - description: Transaction state of this transaction - example: complete note: type: string description: A note that has been entered for this transaction. @@ -14122,20 +20481,25 @@ components: example: Test transaction. partnerExternalId: type: string - description: "External Id of this entity, managed by you." + description: "**Note: This has been deprecated and will be null always.**External\ + \ Id of this entity, managed by you." nullable: true example: ACME-12345 + deprecated: true partnerCustomPayload: type: array - description: "Custom JSON payload for this entity, managed by you." + description: "**Note: This has been deprecated and will be null always.**Custom\ + \ JSON payload for this entity, managed by you." nullable: true + deprecated: true items: type: object metadata: + description: Additional information for this transaction nullable: true allOf: - - $ref: '#/components/schemas/MetadataDto' - - description: Additional information for this transaction + - $ref: "#/components/schemas/MetadataDto" + - {} WalletTransactionGroup: type: string enum: @@ -14177,13 +20541,14 @@ components: - other WebhookConfig: required: + - eventTypes - webhookSecret - webhookUrl type: object properties: webhookUrl: maxLength: 191 - pattern: https://.* + pattern: https://(?!(.*monta\.com?)).* required: - "true" type: string @@ -14200,13 +20565,14 @@ components: eventTypes: maxItems: 512 required: - - "false" + - "true" type: array - description: "A list of event type to subscribe to. Use [\"*\"] to subscribe\ - \ to all." - example: "[\"charges\", \"team-members\"]" + description: A list of event types to subscribe to. + example: + - charges + - team-members items: - $ref: '#/components/schemas/WebhookEntry.EventType' + $ref: "#/components/schemas/WebhookEntry.EventType" WebhookEntry: required: - createdAt @@ -14231,28 +20597,34 @@ components: format: int64 example: 1 eventType: + description: "\n Type of event this entry belongs to.\n \ + \ Note: This is not the type of the entity (payload.EntityType),\ + \ but the type of the event that you can subscribe to.\n " + example: charge-points allOf: - - $ref: '#/components/schemas/WebhookEntry.EventType' - - description: "\n Type of event this entry belongs to.\n \ - \ Note: This is not the type of the entity (payload.EntityType),\ - \ but the type of the event that you can subscribe to.\n " - example: charge-points + - $ref: "#/components/schemas/WebhookEntry.EventType" + - {} payload: + description: payload of this entry + example: "See [Charge](/reference/get-charge) payload" allOf: - - $ref: '#/components/schemas/WebhookEntryPayload' - - description: payload of this entry - example: "See [Charge](/reference/get-charge) payload" + - $ref: "#/components/schemas/WebhookEntryPayload" + - {} status: + description: Status of the entry + example: completed allOf: - - $ref: '#/components/schemas/WebhookEntry.Status' - - description: Status of the entry - example: completed + - $ref: "#/components/schemas/WebhookEntry.Status" + - {} error: + description: Contains the error message if the delivery failed nullable: true + example: + errorCode: "500" + errorMessage: "Bad Gateway: The server is unreachable at this time." allOf: - - $ref: '#/components/schemas/WebhookEntryErrorPayload' - - description: Contains the error message if the delivery failed - example: TBD + - $ref: "#/components/schemas/WebhookEntryErrorPayload" + - {} createdAt: type: string description: Creation date of this entry @@ -14267,10 +20639,10 @@ components: WebhookEntry.EventType: type: string enum: - - '*' - charges - charge-points - sites + - users - team-members - teams - installer-jobs @@ -14278,6 +20650,8 @@ components: - price-groups - subscriptions - plans + - charge-auth-tokens + - reports WebhookEntry.Status: type: string enum: @@ -14313,24 +20687,34 @@ components: type: object properties: entityType: + description: Type of the entity + example: charge allOf: - - $ref: '#/components/schemas/WebhookEntryPayload.EntityType' - - description: Type of the entity - example: charge + - $ref: "#/components/schemas/WebhookEntryPayload.EntityType" + - {} entityId: type: string description: Id of the entity example: "42" eventType: + description: Type of the event + example: updated allOf: - - $ref: '#/components/schemas/KafkaEventType' - - description: Type of the event - example: updated + - $ref: "#/components/schemas/KafkaEventType" + - {} + eventTime: + type: string + description: The timestamp indicating when the event was generated + format: date-time + nullable: true + example: 2024-10-22T16:56:45.999Z payload: type: array description: "payload of this entity, e.g. a full Charge object" nullable: true - example: "{ \"id\": \"42\", \"amount\": 1000 }}" + example: + - id: "42" + amount: 1000 items: type: object WebhookEntryPayload.EntityType: @@ -14339,6 +20723,7 @@ components: - charge - charge-point - site + - user - team - team-member - installer-job @@ -14346,7 +20731,10 @@ components: - price-group - subscription - plan + - charge-auth-token + - report securitySchemes: BearerAccessToken: type: http - scheme: bearer \ No newline at end of file + scheme: bearer +x-stability-level: stable diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargeAuthTokens/ChargeAuthToken.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargeAuthTokens/ChargeAuthToken.verified.cs index bd3770c8e..83cea5a30 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargeAuthTokens/ChargeAuthToken.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargeAuthTokens/ChargeAuthToken.verified.cs @@ -54,6 +54,9 @@ public class ChargeAuthToken /// public string? Name { get; set; } + /// + /// Operator of this charge auth token. + /// public Operator? Operator { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargeAuthTokens/CreateChargeAuthToken.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargeAuthTokens/CreateChargeAuthToken.verified.cs index e60f320b7..fd5aca7e8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargeAuthTokens/CreateChargeAuthToken.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargeAuthTokens/CreateChargeAuthToken.verified.cs @@ -33,6 +33,9 @@ public class CreateChargeAuthToken [RegularExpression("^(?!VID:)[\\s\\S]*")] public string Identifier { get; set; } + /// + /// Type of the charge auth token. + /// [Required] public ChargeAuthenticationType Type { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointIntegrations/ChargePointIntegration.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointIntegrations/ChargePointIntegration.verified.cs index cf8613de4..663b1e202 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointIntegrations/ChargePointIntegration.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointIntegrations/ChargePointIntegration.verified.cs @@ -17,6 +17,9 @@ public class ChargePointIntegration /// public long Id { get; set; } + /// + /// The current state of the charge point integration. + /// [Required] public ChargePointIntegrationStateDto State { get; set; } @@ -37,6 +40,9 @@ public class ChargePointIntegration /// public int? ConnectorId { get; set; } + /// + /// The charge point associated to this integration. + /// [Required] public ChargePoint ChargePoint { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointModels/ChargePointModel.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointModels/ChargePointModel.verified.cs index f69530d93..c11cab51a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointModels/ChargePointModel.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointModels/ChargePointModel.verified.cs @@ -29,6 +29,9 @@ public class ChargePointModel [Required] public string Name { get; set; } + /// + /// The brand of the charge point model. + /// [Required] public ChargePointModelDtoChargePointBrandDto Brand { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/ChargePointStatisticsDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/ChargePointStatisticsDto.verified.cs new file mode 100644 index 000000000..acfc17850 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/ChargePointStatisticsDto.verified.cs @@ -0,0 +1,68 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePointStatistics; + +/// +/// ChargePointStatisticsDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ChargePointStatisticsDto +{ + /// + /// Start date of the statistics period. + /// + [Required] + public DateTimeOffset FromDate { get; set; } + + /// + /// End date of the statistics period. + /// + [Required] + public DateTimeOffset ToDate { get; set; } + + /// + /// Total energy consumed during the period (in kWh). + /// + [Required] + public double TotalEnergyConsumed { get; set; } + + /// + /// Total number of charging sessions during the period. + /// + [Required] + public int TotalSessions { get; set; } + + /// + /// Success rate of charging sessions during the period (as a percentage). + /// + [Required] + public double SessionSuccessRate { get; set; } + + /// + /// Percentage of uptime for the system during the period. + /// + public double? SystemUptimePercentage { get; set; } + + /// + /// Detailed state for the period. + /// + public List States { get; set; } = new List(); + + /// + /// Daily statistics for the period. + /// + public List Days { get; set; } = new List(); + + /// + /// Monthly statistics for the period. + /// + public List Months { get; set; } = new List(); + + /// + public override string ToString() + => $"{nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(TotalEnergyConsumed)}: {TotalEnergyConsumed}, {nameof(TotalSessions)}: {TotalSessions}, {nameof(SessionSuccessRate)}: {SessionSuccessRate}, {nameof(SystemUptimePercentage)}: {SystemUptimePercentage}, {nameof(States)}.Count: {States?.Count ?? 0}, {nameof(Days)}.Count: {Days?.Count ?? 0}, {nameof(Months)}.Count: {Months?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/Performance.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/Performance.verified.cs new file mode 100644 index 000000000..97c4818ee --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/Performance.verified.cs @@ -0,0 +1,30 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePointStatistics; + +/// +/// Performance. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Performance +{ + /// + /// State of the system or charge point. + /// + [Required] + public string Status { get; set; } + + /// + /// Percentage of time in this state. + /// + [Required] + public double UsagePercentage { get; set; } + + /// + public override string ToString() + => $"{nameof(Status)}: {Status}, {nameof(UsagePercentage)}: {UsagePercentage}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/RequestParameters/GetChargePointStatisticsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/RequestParameters/GetChargePointStatisticsParameters.verified.cs new file mode 100644 index 000000000..034adbdcc --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/RequestParameters/GetChargePointStatisticsParameters.verified.cs @@ -0,0 +1,32 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePointStatistics; + +/// +/// Parameters for operation request. +/// Description: Retrieve statistics related to a charge point. +/// Operation: GetChargePointStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetChargePointStatisticsParameters +{ + [Required] + [Range(0, 2147483647)] + public long ChargePointId { get; set; } + + [Required] + [RegularExpression("\\d{4}-\\d{2}-\\d{2}")] + public DateTimeOffset FromDate { get; set; } + + [Required] + [RegularExpression("\\d{4}-\\d{2}-\\d{2}")] + public DateTimeOffset ToDate { get; set; } + + /// + public override string ToString() + => $"{nameof(ChargePointId)}: {ChargePointId}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/RequestParameters/GetSiteStatisticsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/RequestParameters/GetSiteStatisticsParameters.verified.cs new file mode 100644 index 000000000..ef21177d4 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/RequestParameters/GetSiteStatisticsParameters.verified.cs @@ -0,0 +1,32 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePointStatistics; + +/// +/// Parameters for operation request. +/// Description: Retrieve statistics related to a site. +/// Operation: GetSiteStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetSiteStatisticsParameters +{ + [Required] + [Range(0, 2147483647)] + public long SiteId { get; set; } + + [Required] + [RegularExpression("\\d{4}-\\d{2}-\\d{2}")] + public DateTimeOffset FromDate { get; set; } + + [Required] + [RegularExpression("\\d{4}-\\d{2}-\\d{2}")] + public DateTimeOffset ToDate { get; set; } + + /// + public override string ToString() + => $"{nameof(SiteId)}: {SiteId}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/States.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/States.verified.cs new file mode 100644 index 000000000..7d3474561 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/States.verified.cs @@ -0,0 +1,36 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePointStatistics; + +/// +/// States. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class States +{ + /// + /// State of the system or charge point. + /// + [Required] + public string State { get; set; } + + /// + /// Percentage of the time spent in this state. + /// + [Required] + public double Percentage { get; set; } + + /// + /// Duration in this state (in seconds). + /// + [Required] + public long Duration { get; set; } + + /// + public override string ToString() + => $"{nameof(State)}: {State}, {nameof(Percentage)}: {Percentage}, {nameof(Duration)}: {Duration}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/TimePeriod.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/TimePeriod.verified.cs new file mode 100644 index 000000000..277889d54 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePointStatistics/TimePeriod.verified.cs @@ -0,0 +1,30 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePointStatistics; + +/// +/// TimePeriod. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class TimePeriod +{ + /// + /// Date for the statistics. + /// + [Required] + public DateTimeOffset Date { get; set; } + + /// + /// Performance metrics for the day. + /// + [Required] + public List DailyPerformance { get; set; } + + /// + public override string ToString() + => $"{nameof(Date)}: ({Date}), {nameof(DailyPerformance)}.Count: {DailyPerformance?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/ChargePointOcppLog.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/ChargePointOcppLog.verified.cs new file mode 100644 index 000000000..53a9e2980 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/ChargePointOcppLog.verified.cs @@ -0,0 +1,30 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePoints; + +/// +/// ChargePointOcppLog. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ChargePointOcppLog +{ + /// + /// Timestamp of the OCPP log. + /// + [Required] + public DateTimeOffset Timestamp { get; set; } + + /// + /// Message content of the OCPP log, can be a string or an array of mixed types. + /// + [Required] + public string Message { get; set; } + + /// + public override string ToString() + => $"{nameof(Timestamp)}: ({Timestamp}), {nameof(Message)}: {Message}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/CreateChargePoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/CreateChargePoint.verified.cs index c93eeb9c4..3ee25d28a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/CreateChargePoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/CreateChargePoint.verified.cs @@ -46,9 +46,15 @@ public class CreateChargePoint [Required] public double MaxKw { get; set; } + /// + /// Visibility type of the charge point. + /// [Required] public VisibilityType Visibility { get; set; } + /// + /// Electric current type the charge point support. + /// [Required] public ElectricCurrentType Type { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResult.verified.cs index 710ae8e80..4664281c2 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResult.verified.cs @@ -12,12 +12,21 @@ namespace Monta.ApiClient.Generated.Contracts.ChargePoints; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class MapResult { + /// + /// list of all charge points found in that area. + /// [Required] public List ChargePoints { get; set; } + /// + /// list of all sites found in that area. + /// [Required] public List Sites { get; set; } + /// + /// list of all clusters (of charge points and sites) found in that area. + /// [Required] public List Cluster { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultChargePoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultChargePoint.verified.cs index a00725a32..196b1079d 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultChargePoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultChargePoint.verified.cs @@ -53,6 +53,9 @@ public class MapResultChargePoint /// public string? State { get; set; } + /// + /// Location information for this charge point. + /// [Required] public Location Location { get; set; } @@ -62,6 +65,9 @@ public class MapResultChargePoint [Required] public List Connectors { get; set; } + /// + /// Deeplinks to open charge screen in Monta app or web. + /// [Required] public ChargePointDeeplinks Deeplinks { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultCluster.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultCluster.verified.cs index 6136723f0..52619e887 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultCluster.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultCluster.verified.cs @@ -12,6 +12,9 @@ namespace Monta.ApiClient.Generated.Contracts.ChargePoints; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class MapResultCluster { + /// + /// Coordinates of the cluster. + /// [Required] public Coordinates Coordinates { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultSite.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultSite.verified.cs index 53869087f..24b12bfd3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultSite.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MapResultSite.verified.cs @@ -49,6 +49,9 @@ public class MapResultSite /// public string? Note { get; set; } + /// + /// Location information for this site. + /// [Required] public Location Location { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MontaPageChargePointOcppLogDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MontaPageChargePointOcppLogDto.verified.cs new file mode 100644 index 000000000..ece6e7caa --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/MontaPageChargePointOcppLogDto.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePoints; + +/// +/// MontaPageChargePointOcppLogDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class MontaPageChargePointOcppLogDto +{ + [Required] + public List Data { get; set; } + + [Required] + public MontaPageMeta Meta { get; set; } + + /// + public override string ToString() + => $"{nameof(Data)}.Count: {Data?.Count ?? 0}, {nameof(Meta)}: ({Meta})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/PatchChargePoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/PatchChargePoint.verified.cs index aff50a69f..e0d5854dd 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/PatchChargePoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/PatchChargePoint.verified.cs @@ -29,8 +29,14 @@ public class PatchChargePoint /// public double? MaxKw { get; set; } + /// + /// Visibility type of the charge point. + /// public VisibilityType? Visibility { get; set; } + /// + /// Electric current type the charge point support. + /// [Required] public ElectricCurrentType? Type { get; set; } @@ -62,7 +68,12 @@ public class PatchChargePoint public string? PartnerExternalId { get; set; } /// - /// Custom JSON payload for this entity, managed by you. + /// Custom JSON payload managed by you. + /// <br />To override default values or provide additional metadata. + /// Can include keys like `custom_roaming_name` and `custom_roaming_evse_id` for roaming charge points, + /// if so the fields must follow the correct format. + /// The payload is limited to 1000 characters overall. + /// . /// public List? PartnerCustomPayload { get; set; } = new List(); diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/GetChargePointOcppLogsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/GetChargePointOcppLogsParameters.verified.cs new file mode 100644 index 000000000..81852c37c --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/GetChargePointOcppLogsParameters.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePoints; + +/// +/// Parameters for operation request. +/// Description: Retrieve charge point OCPP logs. +/// Operation: GetChargePointOcppLogs. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetChargePointOcppLogsParameters +{ + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + + [Required] + public long ChargePointId { get; set; } + + public DateTimeOffset? FromDate { get; set; } + + public DateTimeOffset? ToDate { get; set; } + + /// + public override string ToString() + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(ChargePointId)}: {ChargePointId}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/GetChargePointsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/GetChargePointsParameters.verified.cs index 0cdeadea2..91e56695f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/GetChargePointsParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/GetChargePointsParameters.verified.cs @@ -33,11 +33,17 @@ public class GetChargePointsParameters [RegularExpression("^(-?\\d*\\.\\d+|\\d+\\.\\d*)(,)(-?\\d*\\.\\d+|\\d+\\.\\d*)$")] public string? SortByLocation { get; set; } - public bool? IncludeDeleted { get; set; } + public string? BoundingBox { get; set; } + + public long? OperatorId { get; set; } + + public bool IncludeDeleted { get; set; } = false; + + public bool IncludePublic { get; set; } = false; public ChargePointState? State { get; set; } /// public override string ToString() - => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(SiteId)}: {SiteId}, {nameof(TeamId)}: {TeamId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(SortByLocation)}: {SortByLocation}, {nameof(IncludeDeleted)}: {IncludeDeleted}, {nameof(State)}: ({State})"; + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(SiteId)}: {SiteId}, {nameof(TeamId)}: {TeamId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(SortByLocation)}: {SortByLocation}, {nameof(BoundingBox)}: {BoundingBox}, {nameof(OperatorId)}: {OperatorId}, {nameof(IncludeDeleted)}: {IncludeDeleted}, {nameof(IncludePublic)}: {IncludePublic}, {nameof(State)}: ({State})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/RebootChargePointParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/RebootChargePointParameters.verified.cs new file mode 100644 index 000000000..ca468ed09 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/RebootChargePointParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePoints; + +/// +/// Parameters for operation request. +/// Description: Reboot an existing charge point. +/// Operation: RebootChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class RebootChargePointParameters +{ + [Required] + public long ChargePointId { get; set; } + + /// + public override string ToString() + => $"{nameof(ChargePointId)}: {ChargePointId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/UnlockChargePointParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/UnlockChargePointParameters.verified.cs new file mode 100644 index 000000000..3f37e4e2e --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/ChargePoints/RequestParameters/UnlockChargePointParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.ChargePoints; + +/// +/// Parameters for operation request. +/// Description: Unlock an existing charge point. +/// Operation: UnlockChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UnlockChargePointParameters +{ + [Required] + public long ChargePointId { get; set; } + + /// + public override string ToString() + => $"{nameof(ChargePointId)}: {ChargePointId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/BreakdownSummary.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/BreakdownSummary.verified.cs index cd2eef0da..a69282346 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/BreakdownSummary.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/BreakdownSummary.verified.cs @@ -42,7 +42,12 @@ public class BreakdownSummary [Required] public long TotalPrice { get; set; } + /// + /// Total discount applied for the given charge. + /// + public long? TotalDiscount { get; set; } + /// public override string ToString() - => $"{nameof(TotalMasterPrice)}: {TotalMasterPrice}, {nameof(TotalSecondaryPrice)}: {TotalSecondaryPrice}, {nameof(TotalFees)}: {TotalFees}, {nameof(TotalAdjustments)}: {TotalAdjustments}, {nameof(TotalPrice)}: {TotalPrice}"; + => $"{nameof(TotalMasterPrice)}: {TotalMasterPrice}, {nameof(TotalSecondaryPrice)}: {TotalSecondaryPrice}, {nameof(TotalFees)}: {TotalFees}, {nameof(TotalAdjustments)}: {TotalAdjustments}, {nameof(TotalPrice)}: {TotalPrice}, {nameof(TotalDiscount)}: {TotalDiscount}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Charge.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Charge.verified.cs index fc14b0d22..dffa823ca 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Charge.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Charge.verified.cs @@ -17,11 +17,20 @@ public class Charge /// public long Id { get; set; } + /// + /// User that performed the charge. + /// [Required] - public PublicUser User { get; set; } + public PublicUser3 User { get; set; } + /// + /// Team that performed the charge, if part of the charge points' team. + /// public SimpleTeamMemberDto? TeamMember { get; set; } + /// + /// Type of the charge. + /// [Required] public ChargeType Type { get; set; } @@ -30,6 +39,9 @@ public class Charge /// public long ChargePointId { get; set; } + /// + /// The public information about the charge point related to this charge. + /// [Required] public PublicChargePoint PublicChargePoint { get; set; } @@ -106,6 +118,9 @@ public class Charge /// public DateTimeOffset? CompletedAt { get; set; } + /// + /// State of the charge. + /// [Required] public ChargeStateDto State { get; set; } @@ -185,16 +200,34 @@ public class Charge /// public string? Note { get; set; } - public Currency? Currency { get; set; } + /// + /// Currency used for payment. + /// + public Currency11? Currency { get; set; } + /// + /// Team who paid for this charge. + /// public PayingTeam? PayingTeam { get; set; } + /// + /// Team who sponsored this charge. + /// public SponsorTeam? SponsorTeam { get; set; } + /// + /// Operator this of this charge. + /// public Operator? Operator { get; set; } + /// + /// The object used to authenticate a charge. + /// public ChargeAuthentication? ChargeAuth { get; set; } + /// + /// Information about the state of charge if available. + /// public StateOfCharge? Soc { get; set; } /// @@ -202,6 +235,9 @@ public class Charge /// public double? SocLimit { get; set; } + /// + /// Generic payment session for this charge. If provided, the charge was paid with this payment session. + /// public GenericPaymentSession? GenericPaymentSession { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargeBreakdown.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargeBreakdown.verified.cs index 530d76c59..a742fb0b4 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargeBreakdown.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargeBreakdown.verified.cs @@ -18,9 +18,15 @@ public class ChargeBreakdown [Required] public long ChargeId { get; set; } + /// + /// The price breakdown, Includes information necessary to understand the composition of the final charge price. + /// [Required] public DetailedBreakdown PriceBreakdown { get; set; } + /// + /// The cost breakdown is similar to the price breakdown but focuses on the costs incurred for the given charge. + /// [Required] public DetailedBreakdown CostBreakdown { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargesInsight.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargesInsight.verified.cs index 65637d8ac..84871cd9c 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargesInsight.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargesInsight.verified.cs @@ -12,6 +12,9 @@ namespace Monta.ApiClient.Generated.Contracts.Charges; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class ChargesInsight { + /// + /// The type of charge insight. + /// [Required] public ChargesInsightTypeDto Type { get; set; } @@ -33,11 +36,17 @@ public class ChargesInsight [Required] public string Title { get; set; } + /// + /// The operator to which this charge insight belongs to. + /// [Required] public Operator Operator { get; set; } + /// + /// The currency applicable for this charge insight. + /// [Required] - public Currency Currency { get; set; } + public Currency5 Currency { get; set; } /// /// The compilation of insights entries composing this charge insight. diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargesInsightEntry.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargesInsightEntry.verified.cs index a4444f7f1..ad93a40c9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargesInsightEntry.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/ChargesInsightEntry.verified.cs @@ -12,9 +12,15 @@ namespace Monta.ApiClient.Generated.Contracts.Charges; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class ChargesInsightEntry { + /// + /// The type for this insight entry. + /// [Required] public ChargesInsightEntryTypeDto Type { get; set; } + /// + /// The summary for this insight entry, The summary contains the compiled statistics for the entry. + /// [Required] public ChargesInsightSummary Summary { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Component.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Component.verified.cs index bf6e7f299..802758665 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Component.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Component.verified.cs @@ -12,6 +12,9 @@ namespace Monta.ApiClient.Generated.Contracts.Charges; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class Component { + /// + /// The type of price/fee for this component. + /// [Required] public ComponentTypeDto Type { get; set; } @@ -33,8 +36,14 @@ public class Component [Required] public bool MasterPricing { get; set; } + /// + /// The tag for this component. + /// public PriceGroupTag? Tag { get; set; } + /// + /// Additional information (metadata) for this component, e.g tariffId, kwh and others. + /// public ComponentMetadataDto? Metadata { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/CurrencyDto4.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency11.verified.cs similarity index 59% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/CurrencyDto4.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency11.verified.cs index 5662ff611..ba1fff75b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/CurrencyDto4.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency11.verified.cs @@ -4,29 +4,25 @@ // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. //------------------------------------------------------------------------------ -namespace Monta.ApiClient.Generated.Contracts.Currencies; +namespace Monta.ApiClient.Generated.Contracts.Charges; /// -/// CurrencyDto4. +/// Currency11. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public class CurrencyDto4 +public class Currency11 { /// - /// id of the currency. + /// Currency identifier, e.g. dkk. /// - [Range(0, int.MaxValue)] - public long? Id { get; set; } - - /// - /// Currency identifier, e.g. DKK. - /// - public string? Identifier { get; set; } + [Required] + public string Identifier { get; set; } /// /// Readable name of currency. /// - public string? Name { get; set; } + [Required] + public string Name { get; set; } /// /// Number of decimals for this currency. @@ -35,5 +31,5 @@ public class CurrencyDto4 /// public override string ToString() - => $"{nameof(Id)}: {Id}, {nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency5.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency5.verified.cs new file mode 100644 index 000000000..05b7b473a --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency5.verified.cs @@ -0,0 +1,35 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Charges; + +/// +/// Currency5. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Currency5 +{ + /// + /// Currency identifier, e.g. dkk. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Readable name of currency. + /// + [Required] + public string Name { get; set; } + + /// + /// Number of decimals for this currency. + /// + public int Decimals { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency9.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency9.verified.cs new file mode 100644 index 000000000..6e687b650 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/Currency9.verified.cs @@ -0,0 +1,35 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Charges; + +/// +/// Currency9. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Currency9 +{ + /// + /// Currency identifier, e.g. dkk. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Readable name of currency. + /// + [Required] + public string Name { get; set; } + + /// + /// Number of decimals for this currency. + /// + public int Decimals { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/DetailedBreakdown.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/DetailedBreakdown.verified.cs index 581657515..419f58f03 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/DetailedBreakdown.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/DetailedBreakdown.verified.cs @@ -12,11 +12,17 @@ namespace Monta.ApiClient.Generated.Contracts.Charges; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class DetailedBreakdown { + /// + /// The summary of the total prices for this breakdown. + /// [Required] public BreakdownSummary Summary { get; set; } + /// + /// The currency applicable for this breakdown (for all the components: prices, fees, adjustments). + /// [Required] - public Currency Currency { get; set; } + public Currency9 Currency { get; set; } /// /// The breakdown entries for this breakdown, currently organized on an hourly basis. diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/GenericPaymentSession.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/GenericPaymentSession.verified.cs index 59a26e791..73f96f5f9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/GenericPaymentSession.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/GenericPaymentSession.verified.cs @@ -39,7 +39,12 @@ public class GenericPaymentSession /// public string? CardLast4 { get; set; } + /// + /// The amount of the payment session. Negative amounts will be rejected by the API. + /// + public double? Amount { get; set; } + /// public override string ToString() - => $"{nameof(Provider)}: {Provider}, {nameof(ExternalId)}: {ExternalId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(CardBrand)}: {CardBrand}, {nameof(CardLast4)}: {CardLast4}"; + => $"{nameof(Provider)}: {Provider}, {nameof(ExternalId)}: {ExternalId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(CardBrand)}: {CardBrand}, {nameof(CardLast4)}: {CardLast4}, {nameof(Amount)}: {Amount}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PatchCharge.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PatchCharge.verified.cs index 87b8bcc35..a3f76574f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PatchCharge.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PatchCharge.verified.cs @@ -12,7 +12,10 @@ namespace Monta.ApiClient.Generated.Contracts.Charges; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class PatchCharge { - public GenericPaymentSession? GenericPaymentSession { get; set; } + /// + /// For Partners who want to start charging from payment terminals, kiosks etc. Used to link charge transaction against your billing and to allow users retrieving receipts via receipt.monta.com by using date and `genericPaymentSession.externalId`or `genericPaymentSession.cardLast4`.<br/><br/>**Note: This field is optional, but if provided, you need to provide the full data, since it will be overwritten with values from this object.**. + /// + public PatchGenericPaymentSession? GenericPaymentSession { get; set; } /// /// External Id of this entity, managed by you. diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PatchGenericPaymentSession.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PatchGenericPaymentSession.verified.cs new file mode 100644 index 000000000..28dceed84 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PatchGenericPaymentSession.verified.cs @@ -0,0 +1,50 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Charges; + +/// +/// PatchGenericPaymentSession. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PatchGenericPaymentSession +{ + /// + /// The provider of the payment session. + /// + [Required] + public string Provider { get; set; } + + /// + /// The external id of the payment session. Allows retrieving receipts via receipt.monta.com by using date and `externalId` or `cardLast4`. + /// + [Required] + public string ExternalId { get; set; } + + /// + /// External Id of this entity, managed by you. + /// + public string? PartnerExternalId { get; set; } + + /// + /// The brand of the card used for the payment session. + /// + public string? CardBrand { get; set; } + + /// + /// The last 4 digits of the card used for the payment session. Allows retrieving receipts via receipt.monta.com by using date and `externalId` or `cardLast4`. + /// + public string? CardLast4 { get; set; } + + /// + /// The amount of the payment session. Negative amounts will be rejected by the API. + /// + public double? Amount { get; set; } + + /// + public override string ToString() + => $"{nameof(Provider)}: {Provider}, {nameof(ExternalId)}: {ExternalId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(CardBrand)}: {CardBrand}, {nameof(CardLast4)}: {CardLast4}, {nameof(Amount)}: {Amount}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PublicChargePoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PublicChargePoint.verified.cs index 8e64f40be..b023ffda8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PublicChargePoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PublicChargePoint.verified.cs @@ -34,6 +34,9 @@ public class PublicChargePoint [Required] public string ChargePointOperatorName { get; set; } + /// + /// Location information for this charge point. + /// [Required] public Location Location { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PublicUser.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PublicUser3.verified.cs similarity index 88% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PublicUser.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PublicUser3.verified.cs index 4505f7646..c155e8d11 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PublicUser.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/PublicUser3.verified.cs @@ -4,13 +4,13 @@ // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. //------------------------------------------------------------------------------ -namespace Monta.ApiClient.Generated.Contracts; +namespace Monta.ApiClient.Generated.Contracts.Charges; /// -/// PublicUser. +/// PublicUser3. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public class PublicUser +public class PublicUser3 { /// /// Id of the user. diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/RequestParameters/GetChargesParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/RequestParameters/GetChargesParameters.verified.cs index 220b64ec5..e8961ac9f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/RequestParameters/GetChargesParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/RequestParameters/GetChargesParameters.verified.cs @@ -26,6 +26,8 @@ public class GetChargesParameters public long? TeamId { get; set; } + public long? OperatorId { get; set; } + public long? ChargePointId { get; set; } public long? SiteId { get; set; } @@ -42,9 +44,9 @@ public class GetChargesParameters public string? PartnerExternalId { get; set; } - public OperatorRole? OperatorRole { get; set; } + public OperatorRole? OperatorRole { get; set; } = Contracts.OperatorRole.Owner; /// public override string ToString() - => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(ChargePointId)}: {ChargePointId}, {nameof(SiteId)}: {SiteId}, {nameof(State)}: {State}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(ChargeAuthType)}: ({ChargeAuthType}), {nameof(ChargeAuthId)}: {ChargeAuthId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(OperatorRole)}: ({OperatorRole})"; + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(OperatorId)}: {OperatorId}, {nameof(ChargePointId)}: {ChargePointId}, {nameof(SiteId)}: {SiteId}, {nameof(State)}: {State}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(ChargeAuthType)}: ({ChargeAuthType}), {nameof(ChargeAuthId)}: {ChargeAuthId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(OperatorRole)}: ({OperatorRole})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/StartChargeRequest.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/StartChargeRequest.verified.cs index 40b321048..3526ea6b0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/StartChargeRequest.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Charges/StartChargeRequest.verified.cs @@ -40,16 +40,24 @@ public class StartChargeRequest /// public double? SocLimit { get; set; } + /// + /// The charge price limit, meaning the charge will stop once the price limit is reached. <br />*Note*: `priceLimit` will be in the currency of the charge point. + /// + public double? PriceLimit { get; set; } + /// /// Allows you to enforce a specific price group for this charge. <br />*Note*: The price group must be of type `team` or `charge-point`. /// [Range(0, int.MaxValue)] public long? PriceGroupId { get; set; } + /// + /// For Partners who want to start charging from payment terminals, kiosks etc. Used to link charge transaction against your billing and to allow users retrieving receipts via receipt.monta.com by using date and `genericPaymentSession.externalId`or `genericPaymentSession.cardLast4`. + /// public GenericPaymentSession? GenericPaymentSession { get; set; } /// - /// External Id of this entity, managed by you. + /// External Id of this entity, managed by you. <br />*Note*: How this field is used is up to the partner, but we highly recommend using a unique `partnerExternalId` for each `charge`. /// public string? PartnerExternalId { get; set; } @@ -60,5 +68,5 @@ public class StartChargeRequest /// public override string ToString() - => $"{nameof(PayingTeamId)}: {PayingTeamId}, {nameof(ChargePointId)}: {ChargePointId}, {nameof(ReserveCharge)}: {ReserveCharge}, {nameof(KwhLimit)}: {KwhLimit}, {nameof(SocLimit)}: {SocLimit}, {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(GenericPaymentSession)}: ({GenericPaymentSession}), {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; + => $"{nameof(PayingTeamId)}: {PayingTeamId}, {nameof(ChargePointId)}: {ChargePointId}, {nameof(ReserveCharge)}: {ReserveCharge}, {nameof(KwhLimit)}: {KwhLimit}, {nameof(SocLimit)}: {SocLimit}, {nameof(PriceLimit)}: {PriceLimit}, {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(GenericPaymentSession)}: ({GenericPaymentSession}), {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/CountryAreas/CountryArea.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/CountryAreas/CountryArea.verified.cs index 215924fde..45b61e022 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/CountryAreas/CountryArea.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/CountryAreas/CountryArea.verified.cs @@ -35,6 +35,9 @@ public class CountryArea /// public string? ExternalId { get; set; } + /// + /// The level of depth for this country area. + /// [Required] public CountryAreaLevel Level { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/MontaPageCurrencyDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/MontaPageCurrencyDto.verified.cs index 0c92b90e7..cb7a9fc91 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/MontaPageCurrencyDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/MontaPageCurrencyDto.verified.cs @@ -13,7 +13,7 @@ namespace Monta.ApiClient.Generated.Contracts.Currencies; public class MontaPageCurrencyDto { [Required] - public List Data { get; set; } + public List Data { get; set; } [Required] public MontaPageMeta Meta { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightByChargeAuthTokenReportDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightByChargeAuthTokenReportDto.verified.cs new file mode 100644 index 000000000..23b2a3f91 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightByChargeAuthTokenReportDto.verified.cs @@ -0,0 +1,41 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// ChargesInsightByChargeAuthTokenReportDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ChargesInsightByChargeAuthTokenReportDto +{ + /// + /// The id of the charge auth token. + /// + public long Id { get; set; } + + /// + /// The identifier of the charge auth token, Note: without prefix e.g `VID:`. + /// + [Required] + public string Identifier { get; set; } + + /// + /// The method type used for this charge auth token. + /// + [Required] + public string Type { get; set; } + + /// + /// Charge consumptions grouped by `chargeType`. + /// + [Required] + public List Consumptions { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(Identifier)}: {Identifier}, {nameof(Type)}: {Type}, {nameof(Consumptions)}.Count: {Consumptions?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightByChargeAuthTokenReportDtoConsumption.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightByChargeAuthTokenReportDtoConsumption.verified.cs new file mode 100644 index 000000000..d04206e65 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightByChargeAuthTokenReportDtoConsumption.verified.cs @@ -0,0 +1,74 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// ChargesInsightByChargeAuthTokenReportDtoConsumption. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ChargesInsightByChargeAuthTokenReportDtoConsumption +{ + /// + /// Defines the type of charge, ie. if it was a sponsored or public charge. + /// definitions: + /// * `sponsored` - Charges that have been sponsored. + /// * `team-operator` - Charges that belong to Charge Points of the same operator as paying team operator. + /// * `public` - Any charge that was paid for by this team that does not match the other cases. + /// Note that more chargeTypes might be added in the future. Make sure to handle this gracefully. + /// + [Required] + public string ChargeType { get; set; } + + /// + /// Number of charging sessions. + /// + [Required] + public long TotalSessions { get; set; } + + /// + /// Sum of all Kwh consumed. + /// + [Required] + public double TotalKwh { get; set; } + + /// + /// Sum of all charge net prices. + /// + [Required] + public double TotalNetPrice { get; set; } + + /// + /// Sum of all charge vat amounts. + /// + [Required] + public double TotalVat { get; set; } + + /// + /// Sum of all charge gross prices. + /// + [Required] + public double TotalGrossPrice { get; set; } + + /// + /// The ID of the Member Cost Group applied to this charges, or Null if none. + /// + public long? MemberCostGroupId { get; set; } + + /// + /// The name of the Member Cost Group applied to this charges, or Null if none. + /// + public string? MemberCostGroupName { get; set; } + + /// + /// Sum of all charge costs in the Member Cost Group currency, or Null if none. + /// + public double? MemberCostGroupPrice { get; set; } + + /// + public override string ToString() + => $"{nameof(ChargeType)}: {ChargeType}, {nameof(TotalSessions)}: {TotalSessions}, {nameof(TotalKwh)}: {TotalKwh}, {nameof(TotalNetPrice)}: {TotalNetPrice}, {nameof(TotalVat)}: {TotalVat}, {nameof(TotalGrossPrice)}: {TotalGrossPrice}, {nameof(MemberCostGroupId)}: {MemberCostGroupId}, {nameof(MemberCostGroupName)}: {MemberCostGroupName}, {nameof(MemberCostGroupPrice)}: {MemberCostGroupPrice}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReport.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReport.verified.cs new file mode 100644 index 000000000..d9b5b61ca --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReport.verified.cs @@ -0,0 +1,42 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// ChargesInsightDriverMemberCostsReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ChargesInsightDriverMemberCostsReport +{ + /// + /// Team ID used for this report. + /// + [Required] + public long TeamId { get; set; } + + /// + /// Team Member ID of the Driver. + /// + [Required] + public long TeamMemberId { get; set; } + + /// + /// User ID of the Driver. + /// + [Required] + public long UserId { get; set; } + + /// + /// Charge consumptions grouped by `chargeType`. + /// + [Required] + public List Consumptions { get; set; } + + /// + public override string ToString() + => $"{nameof(TeamId)}: {TeamId}, {nameof(TeamMemberId)}: {TeamMemberId}, {nameof(UserId)}: {UserId}, {nameof(Consumptions)}.Count: {Consumptions?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReportDtoConsumption.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReportDtoConsumption.verified.cs new file mode 100644 index 000000000..87d26cc6e --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReportDtoConsumption.verified.cs @@ -0,0 +1,80 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// ChargesInsightDriverMemberCostsReportDtoConsumption. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ChargesInsightDriverMemberCostsReportDtoConsumption +{ + /// + /// Defines the type of charge, ie. if it was a sponsored or public charge. + /// definitions: + /// * `sponsored` - Charges that have been sponsored. + /// * `team-operator` - Charges that belong to Charge Points of the same operator as paying team operator. + /// * `public` - Any charge that was paid for by this team that does not match the other cases. + /// Note that more chargeTypes might be added in the future. Make sure to handle this gracefully. + /// + [Required] + public string ChargeType { get; set; } + + /// + /// Number of charging sessions. + /// + [Required] + public long TotalSessions { get; set; } + + /// + /// Sum of all Kwh consumed. + /// + [Required] + public double TotalKwh { get; set; } + + /// + /// Sum of all charge net prices. + /// + [Required] + public double TotalNetPrice { get; set; } + + /// + /// Sum of all charge vat amounts. + /// + [Required] + public double TotalVat { get; set; } + + /// + /// Sum of all charge gross prices. + /// + [Required] + public double TotalGrossPrice { get; set; } + + /// + /// The ID of the Member Cost Group applied to this charges, or Null if none. + /// + public long? MemberCostGroupId { get; set; } + + /// + /// The name of the Member Cost Group applied to this charges, or Null if none. + /// + public string? MemberCostGroupName { get; set; } + + /// + /// Sum of all charge costs in the Member Cost Group currency, or Null if none. + /// + public double? MemberCostGroupPrice { get; set; } + + /// + /// Breakdown of the charges by country. + /// + [Required] + public List CountryBreakdown { get; set; } + + /// + public override string ToString() + => $"{nameof(ChargeType)}: {ChargeType}, {nameof(TotalSessions)}: {TotalSessions}, {nameof(TotalKwh)}: {TotalKwh}, {nameof(TotalNetPrice)}: {TotalNetPrice}, {nameof(TotalVat)}: {TotalVat}, {nameof(TotalGrossPrice)}: {TotalGrossPrice}, {nameof(MemberCostGroupId)}: {MemberCostGroupId}, {nameof(MemberCostGroupName)}: {MemberCostGroupName}, {nameof(MemberCostGroupPrice)}: {MemberCostGroupPrice}, {nameof(CountryBreakdown)}.Count: {CountryBreakdown?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReportDtoConsumptionCountryBreakdown.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReportDtoConsumptionCountryBreakdown.verified.cs new file mode 100644 index 000000000..2e9e775dd --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/ChargesInsightDriverMemberCostsReportDtoConsumptionCountryBreakdown.verified.cs @@ -0,0 +1,59 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// ChargesInsightDriverMemberCostsReportDtoConsumptionCountryBreakdown. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ChargesInsightDriverMemberCostsReportDtoConsumptionCountryBreakdown +{ + /// + /// Two letter Country Code. + /// + [Required] + public string CountryCode { get; set; } + + /// + /// Number of charging sessions. + /// + [Required] + public long TotalSessions { get; set; } + + /// + /// Sum of all Kwh consumed. + /// + [Required] + public double TotalKwh { get; set; } + + /// + /// Sum of all charge net prices. + /// + [Required] + public double TotalNetPrice { get; set; } + + /// + /// Sum of all charge vat amounts. + /// + [Required] + public double TotalVat { get; set; } + + /// + /// Sum of all charge gross prices. + /// + [Required] + public double TotalGrossPrice { get; set; } + + /// + /// Sum of all charge costs in the Member Cost Group currency, or Null if none. + /// + public double? MemberCostGroupPrice { get; set; } + + /// + public override string ToString() + => $"{nameof(CountryCode)}: {CountryCode}, {nameof(TotalSessions)}: {TotalSessions}, {nameof(TotalKwh)}: {TotalKwh}, {nameof(TotalNetPrice)}: {TotalNetPrice}, {nameof(TotalVat)}: {TotalVat}, {nameof(TotalGrossPrice)}: {TotalGrossPrice}, {nameof(MemberCostGroupPrice)}: {MemberCostGroupPrice}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/MontaPageChargesInsightByChargeAuthTokenReportDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/MontaPageChargesInsightByChargeAuthTokenReportDto.verified.cs new file mode 100644 index 000000000..902e2ce9f --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/MontaPageChargesInsightByChargeAuthTokenReportDto.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// MontaPageChargesInsightByChargeAuthTokenReportDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class MontaPageChargesInsightByChargeAuthTokenReportDto +{ + [Required] + public List Data { get; set; } + + [Required] + public MontaPageMeta Meta { get; set; } + + /// + public override string ToString() + => $"{nameof(Data)}.Count: {Data?.Count ?? 0}, {nameof(Meta)}: ({Meta})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/MontaPageChargesInsightDriverMemberCostsReportDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/MontaPageChargesInsightDriverMemberCostsReportDto.verified.cs new file mode 100644 index 000000000..c69af7eed --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/MontaPageChargesInsightDriverMemberCostsReportDto.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// MontaPageChargesInsightDriverMemberCostsReportDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class MontaPageChargesInsightDriverMemberCostsReportDto +{ + [Required] + public List Data { get; set; } + + [Required] + public MontaPageMeta Meta { get; set; } + + /// + public override string ToString() + => $"{nameof(Data)}.Count: {Data?.Count ?? 0}, {nameof(Meta)}: ({Meta})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesChargeAuthTokenReportParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesChargeAuthTokenReportParameters.verified.cs new file mode 100644 index 000000000..b67b1d698 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesChargeAuthTokenReportParameters.verified.cs @@ -0,0 +1,42 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// Parameters for operation request. +/// Description: Retrieve insights about charges broken down by charge auth token and member cost groups of a team. +/// Operation: GetInsightsChargesChargeAuthTokenReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInsightsChargesChargeAuthTokenReportParameters +{ + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + + [Required] + [Range(0, 2147483647)] + public long TeamId { get; set; } + + [Required] + public DateTimeOffset FromDate { get; set; } + + [Required] + public DateTimeOffset ToDate { get; set; } + + public DriverReportDatesFilteredBy? DatesFilteredBy { get; set; } = DriverReportDatesFilteredBy.ChargeTransaction; + + /// + public override string ToString() + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(DatesFilteredBy)}: ({DatesFilteredBy})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesChargerReportParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesChargerReportParameters.verified.cs index 40bf9ef5c..dcad281ae 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesChargerReportParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesChargerReportParameters.verified.cs @@ -14,7 +14,18 @@ namespace Monta.ApiClient.Generated.Contracts.Insights; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class GetInsightsChargesChargerReportParameters { + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + [Required] + [Range(0, 2147483647)] public long TeamId { get; set; } public string? ChargePointIds { get; set; } @@ -27,5 +38,5 @@ public class GetInsightsChargesChargerReportParameters /// public override string ToString() - => $"{nameof(TeamId)}: {TeamId}, {nameof(ChargePointIds)}: {ChargePointIds}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate})"; + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(ChargePointIds)}: {ChargePointIds}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesDriverMemberCostsReportParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesDriverMemberCostsReportParameters.verified.cs new file mode 100644 index 000000000..c092859fd --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesDriverMemberCostsReportParameters.verified.cs @@ -0,0 +1,44 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Insights; + +/// +/// Parameters for operation request. +/// Description: Retrieve insights about charges broken down by team members and member cost groups of a team. +/// Operation: GetInsightsChargesDriverMemberCostsReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInsightsChargesDriverMemberCostsReportParameters +{ + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + + [Required] + [Range(0, 2147483647)] + public long TeamId { get; set; } + + public string? TeamMemberIds { get; set; } + + [Required] + public DateTimeOffset FromDate { get; set; } + + [Required] + public DateTimeOffset ToDate { get; set; } + + public DriverReportDatesFilteredBy? DatesFilteredBy { get; set; } = DriverReportDatesFilteredBy.ChargeTransaction; + + /// + public override string ToString() + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(TeamMemberIds)}: {TeamMemberIds}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(DatesFilteredBy)}: ({DatesFilteredBy})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesDriverReportParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesDriverReportParameters.verified.cs index f91bfade4..ccf20f588 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesDriverReportParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Insights/RequestParameters/GetInsightsChargesDriverReportParameters.verified.cs @@ -14,7 +14,18 @@ namespace Monta.ApiClient.Generated.Contracts.Insights; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class GetInsightsChargesDriverReportParameters { + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + [Required] + [Range(0, 2147483647)] public long TeamId { get; set; } public string? TeamMemberIds { get; set; } @@ -25,9 +36,9 @@ public class GetInsightsChargesDriverReportParameters [Required] public DateTimeOffset ToDate { get; set; } - public DriverReportDatesFilteredBy? DatesFilteredBy { get; set; } + public DriverReportDatesFilteredBy? DatesFilteredBy { get; set; } = DriverReportDatesFilteredBy.ChargeTransaction; /// public override string ToString() - => $"{nameof(TeamId)}: {TeamId}, {nameof(TeamMemberIds)}: {TeamMemberIds}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(DatesFilteredBy)}: ({DatesFilteredBy})"; + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(TeamMemberIds)}: {TeamMemberIds}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(DatesFilteredBy)}: ({DatesFilteredBy})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/InstallerJobs/InstallerJob.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/InstallerJobs/InstallerJob.verified.cs index 20299ac47..c28e121a6 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/InstallerJobs/InstallerJob.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/InstallerJobs/InstallerJob.verified.cs @@ -22,6 +22,9 @@ public class InstallerJob /// public long SiteId { get; set; } + /// + /// The operator of this installer job. + /// [Required] public Operator Operator { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/InvoiceDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/InvoiceDto.verified.cs new file mode 100644 index 000000000..5628809cc --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/InvoiceDto.verified.cs @@ -0,0 +1,87 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Invoices; + +/// +/// InvoiceDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class InvoiceDto +{ + /// + /// Id of the invoice. + /// + [Required] + public long Id { get; set; } + + /// + /// Id of the wallet. + /// + [Required] + public long WalletId { get; set; } + + /// + /// Invoice from date. + /// + [Required] + public DateTimeOffset From { get; set; } + + /// + /// Invoice to date. + /// + [Required] + public DateTimeOffset To { get; set; } + + /// + /// The date it was approved. + /// + public DateTimeOffset? ApprovedAt { get; set; } + + /// + /// Total statement. + /// + public double? TotalStatement { get; set; } + + /// + /// Total payable balance. + /// + [Required] + public double TotalPayableBalance { get; set; } + + /// + /// Currency. + /// + [Required] + public CurrencyDto Currency { get; set; } + + /// + /// status of the invoice. + /// + [Required] + public string Status { get; set; } + + /// + /// Invoice creation date. + /// + [Required] + public DateTimeOffset CreatedAt { get; set; } + + /// + /// Invoice due date. + /// + [Required] + public DateTimeOffset? DueAt { get; set; } + + /// + /// URL to the invoice PDF. + /// + public string? PdfUrl { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(WalletId)}: {WalletId}, {nameof(From)}: ({From}), {nameof(To)}: ({To}), {nameof(ApprovedAt)}: ({ApprovedAt}), {nameof(TotalStatement)}: {TotalStatement}, {nameof(TotalPayableBalance)}: {TotalPayableBalance}, {nameof(Currency)}: ({Currency}), {nameof(Status)}: {Status}, {nameof(CreatedAt)}: ({CreatedAt}), {nameof(DueAt)}: ({DueAt}), {nameof(PdfUrl)}: {PdfUrl}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/MontaPageInvoiceDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/MontaPageInvoiceDto.verified.cs new file mode 100644 index 000000000..a8ce2d8ad --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/MontaPageInvoiceDto.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Invoices; + +/// +/// MontaPageInvoiceDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class MontaPageInvoiceDto +{ + [Required] + public List Data { get; set; } + + [Required] + public MontaPageMeta Meta { get; set; } + + /// + public override string ToString() + => $"{nameof(Data)}.Count: {Data?.Count ?? 0}, {nameof(Meta)}: ({Meta})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/RequestParameters/GetInvoice1Parameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/RequestParameters/GetInvoice1Parameters.verified.cs new file mode 100644 index 000000000..22b48975d --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/RequestParameters/GetInvoice1Parameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Invoices; + +/// +/// Parameters for operation request. +/// Description: Retrieves an invoice by its id. +/// Operation: GetInvoice1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInvoice1Parameters +{ + [Required] + public long InvoiceId { get; set; } + + /// + public override string ToString() + => $"{nameof(InvoiceId)}: {InvoiceId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/RequestParameters/GetInvoiceParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/RequestParameters/GetInvoiceParameters.verified.cs new file mode 100644 index 000000000..697c30746 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Invoices/RequestParameters/GetInvoiceParameters.verified.cs @@ -0,0 +1,36 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Invoices; + +/// +/// Parameters for operation request. +/// Description: Retrieves a list of invoices by walletId. +/// Operation: GetInvoice. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInvoiceParameters +{ + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + + [Required] + public long WalletId { get; set; } + + [Required] + public Pageable Pageable { get; set; } + + /// + public override string ToString() + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(WalletId)}: {WalletId}, {nameof(Pageable)}: ({Pageable})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/MontaPageNestedTeamDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/MontaPageNestedTeamDto.verified.cs new file mode 100644 index 000000000..2f1ba7790 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/MontaPageNestedTeamDto.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// MontaPageNestedTeamDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class MontaPageNestedTeamDto +{ + [Required] + public List Data { get; set; } + + [Required] + public MontaPageMeta Meta { get; set; } + + /// + public override string ToString() + => $"{nameof(Data)}.Count: {Data?.Count ?? 0}, {nameof(Meta)}: ({Meta})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/NestedTeam.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/NestedTeam.verified.cs new file mode 100644 index 000000000..d31815996 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/NestedTeam.verified.cs @@ -0,0 +1,89 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// NestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class NestedTeam +{ + /// + /// Id of the nested team relation. + /// + public long Id { get; set; } + + /// + /// Parent team, the one who sends the invite. + /// + [Required] + public PublicTeam ParentTeam { get; set; } + + /// + /// Parent team, the one who receives the invite. + /// + [JsonPropertyName("nestedTeam")] + public PublicTeam? NestedTeamProperty { get; set; } + + /// + /// Price group applied to the nested team. + /// + public PriceGroup1? PriceGroup { get; set; } + + /// + /// User who requested the invitation. + /// + public PublicUser? InvitedByUser { get; set; } + + /// + /// The role assigned to the nested team. + /// + [Required] + public string UserRole { get; set; } + + /// + /// Access to parent team CPs / sites: to all or selected charge points and/or sites. + /// + [Required] + public TeamMemberAccess Access { get; set; } + + /// + /// State of the nested team invitation. + /// + [Required] + public TeamMemberState State { get; set; } + + /// + /// Selected charge points nested team has access to. + /// + public List? SelectedChargePointIds { get; set; } = new List(); + + /// + /// Internal note for this nested team. + /// + public string? Note { get; set; } + + /// + /// Datetime of the creation of nested team invite. + /// + [Required] + public DateTimeOffset CreatedAt { get; set; } + + /// + /// Datetime of the update of nested team invite. + /// + public DateTimeOffset? UpdatedAt { get; set; } + + /// + /// Datetime nested team was invited. + /// + public DateTimeOffset? InvitedAt { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(ParentTeam)}: ({ParentTeam}), {nameof(NestedTeamProperty)}: ({NestedTeamProperty}), {nameof(PriceGroup)}: ({PriceGroup}), {nameof(InvitedByUser)}: ({InvitedByUser}), {nameof(UserRole)}: {UserRole}, {nameof(Access)}: ({Access}), {nameof(State)}: ({State}), {nameof(SelectedChargePointIds)}.Count: {SelectedChargePointIds?.Count ?? 0}, {nameof(Note)}: {Note}, {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(InvitedAt)}: ({InvitedAt})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/NestedTeamInvite.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/NestedTeamInvite.verified.cs new file mode 100644 index 000000000..97e4428ca --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/NestedTeamInvite.verified.cs @@ -0,0 +1,52 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// NestedTeamInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class NestedTeamInvite +{ + /// + /// Id of the parent team, the one who sends the invite. + /// + [Required] + public long ParentTeamId { get; set; } + + /// + /// Id of the nested team, the one who receives the invite. + /// + [Required] + public long NestedTeamId { get; set; } + + /// + /// Price group applied to the nested team. + /// + [Required] + public long PriceGroupId { get; set; } + + /// + /// Is access granted to all or selected charge points and sites. + /// + [Required] + public TeamMemberAccess Access { get; set; } + + /// + /// List of charge point ids nested team access will be assigned to. + /// + public List? SelectedChargePointIds { get; set; } = new List(); + + /// + /// List of site ids nested team access will be assigned to. + /// + public List? SelectedSiteIds { get; set; } = new List(); + + /// + public override string ToString() + => $"{nameof(ParentTeamId)}: {ParentTeamId}, {nameof(NestedTeamId)}: {NestedTeamId}, {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(Access)}: ({Access}), {nameof(SelectedChargePointIds)}.Count: {SelectedChargePointIds?.Count ?? 0}, {nameof(SelectedSiteIds)}.Count: {SelectedSiteIds?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PatchNestedTeam.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PatchNestedTeam.verified.cs new file mode 100644 index 000000000..6a68c16c5 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PatchNestedTeam.verified.cs @@ -0,0 +1,34 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// PatchNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PatchNestedTeam +{ + /// + /// Price group applied to the nested team. + /// + public long? PriceGroupId { get; set; } + + /// + /// A note (instructions, warning, information) you have entered for this nested team member. + /// + [StringLength(255)] + public string? Note { get; set; } + + /// + /// List of charge point ids nested team access will be assigned to. + /// + public List? SelectedChargePointIds { get; set; } = new List(); + + /// + public override string ToString() + => $"{nameof(PriceGroupId)}: {PriceGroupId}, {nameof(Note)}: {Note}, {nameof(SelectedChargePointIds)}.Count: {SelectedChargePointIds?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PriceGroup1.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PriceGroup1.verified.cs new file mode 100644 index 000000000..db94ddbd4 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PriceGroup1.verified.cs @@ -0,0 +1,29 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// PriceGroup1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PriceGroup1 +{ + /// + /// Id of the price group. + /// + public long Id { get; set; } + + /// + /// Name of the price group. + /// + [Required] + public string Name { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(Name)}: {Name}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PublicTeam.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PublicTeam.verified.cs new file mode 100644 index 000000000..99d2a2827 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PublicTeam.verified.cs @@ -0,0 +1,33 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// PublicTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PublicTeam +{ + /// + /// Id of the public team. + /// + public long Id { get; set; } + + /// + /// Public name of the team. + /// + public string? PublicName { get; set; } + + /// + /// Number of members in the team. + /// + public long? MemberCount { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(PublicName)}: {PublicName}, {nameof(MemberCount)}: {MemberCount}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PublicUser.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PublicUser.verified.cs new file mode 100644 index 000000000..85fd8c11e --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/PublicUser.verified.cs @@ -0,0 +1,38 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// PublicUser. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PublicUser +{ + /// + /// Id of the user. + /// + public long Id { get; set; } + + /// + /// First name of the user. + /// + public string? FirstName { get; set; } + + /// + /// Last name of the user. + /// + public string? LastName { get; set; } + + /// + /// Display name of the user. + /// + public string? DisplayName { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(FirstName)}: {FirstName}, {nameof(LastName)}: {LastName}, {nameof(DisplayName)}: {DisplayName}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/AcceptInviteParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/AcceptInviteParameters.verified.cs new file mode 100644 index 000000000..9606c4824 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/AcceptInviteParameters.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// Parameters for operation request. +/// Description: Accept a nested team invitation. +/// Operation: AcceptInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class AcceptInviteParameters +{ + [Required] + [Range(0, 2147483647)] + public long RelationId { get; set; } + + /// + public override string ToString() + => $"{nameof(RelationId)}: {RelationId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/DeleteNestedTeamParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/DeleteNestedTeamParameters.verified.cs new file mode 100644 index 000000000..6d79c9991 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/DeleteNestedTeamParameters.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// Parameters for operation request. +/// Description: Delete a nested team relation. +/// Operation: DeleteNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class DeleteNestedTeamParameters +{ + [Required] + [Range(0, 2147483647)] + public long RelationId { get; set; } + + /// + public override string ToString() + => $"{nameof(RelationId)}: {RelationId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/GetNestedTeamParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/GetNestedTeamParameters.verified.cs new file mode 100644 index 000000000..a8f8d7ea1 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/GetNestedTeamParameters.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// Parameters for operation request. +/// Description: Get a nested team by nested team relation id. +/// Operation: GetNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetNestedTeamParameters +{ + [Required] + [Range(0, 2147483647)] + public long RelationId { get; set; } + + /// + public override string ToString() + => $"{nameof(RelationId)}: {RelationId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/GetNestedTeamsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/GetNestedTeamsParameters.verified.cs new file mode 100644 index 000000000..1bf456462 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/GetNestedTeamsParameters.verified.cs @@ -0,0 +1,34 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// Parameters for operation request. +/// Description: Retrieve a list of nested team relations. +/// Operation: GetNestedTeams. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetNestedTeamsParameters +{ + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + + public TeamMemberState? State { get; set; } + + public bool? IncludeDeleted { get; set; } = false; + + /// + public override string ToString() + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(State)}: ({State}), {nameof(IncludeDeleted)}: {IncludeDeleted}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/InviteParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/InviteParameters.verified.cs new file mode 100644 index 000000000..466ba9e05 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/InviteParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// Parameters for operation request. +/// Description: Nested team invite. +/// Operation: Invite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class InviteParameters +{ + [Required] + public NestedTeamInvite Request { get; set; } + + /// + public override string ToString() + => $"{nameof(Request)}: ({Request})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/RejectInviteParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/RejectInviteParameters.verified.cs new file mode 100644 index 000000000..9f17bf791 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/RejectInviteParameters.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// Parameters for operation request. +/// Description: Reject a nested team invitation. +/// Operation: RejectInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class RejectInviteParameters +{ + [Required] + [Range(0, 2147483647)] + public long RelationId { get; set; } + + /// + public override string ToString() + => $"{nameof(RelationId)}: {RelationId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/UpdateNestedTeamParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/UpdateNestedTeamParameters.verified.cs new file mode 100644 index 000000000..ac7560d86 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/NestedTeams/RequestParameters/UpdateNestedTeamParameters.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.NestedTeams; + +/// +/// Parameters for operation request. +/// Description: Update a nested team relation. +/// Operation: UpdateNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UpdateNestedTeamParameters +{ + [Required] + [Range(0, 2147483647)] + public long RelationId { get; set; } + + [Required] + public PatchNestedTeam Request { get; set; } + + /// + public override string ToString() + => $"{nameof(RelationId)}: {RelationId}, {nameof(Request)}: ({Request})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Operators/RequestParameters/GetOperatorsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Operators/RequestParameters/GetOperatorsParameters.verified.cs index faee74e06..0807ef665 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Operators/RequestParameters/GetOperatorsParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Operators/RequestParameters/GetOperatorsParameters.verified.cs @@ -14,9 +14,15 @@ namespace Monta.ApiClient.Generated.Contracts.Operators; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class GetOperatorsParameters { - public int? Page { get; set; } = 0; + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; - public int? PerPage { get; set; } + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; /// public override string ToString() diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PaymentTerminals/PaymentTerminal.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PaymentTerminals/PaymentTerminal.verified.cs index 16eccf088..c360ba0d3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PaymentTerminals/PaymentTerminal.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PaymentTerminals/PaymentTerminal.verified.cs @@ -18,6 +18,9 @@ public class PaymentTerminal [Required] public string Id { get; set; } + /// + /// Type of this terminal, ie "payter". + /// [Required] public PaymentTerminalType Type { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/Currency1.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/Currency1.verified.cs new file mode 100644 index 000000000..6fa9ff34a --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/Currency1.verified.cs @@ -0,0 +1,35 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Plans; + +/// +/// Currency1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Currency1 +{ + /// + /// Currency identifier, e.g. dkk. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Readable name of currency. + /// + [Required] + public string Name { get; set; } + + /// + /// Number of decimals for this currency. + /// + public int Decimals { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/Plan.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/Plan.verified.cs index 7f0f1abe5..0334fcdaa 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/Plan.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/Plan.verified.cs @@ -60,6 +60,9 @@ public class Plan /// public string? SupportEmail { get; set; } + /// + /// Indicates whether this plan can be applied to teams or charge points. 'operator' value is only used internally. + /// [Required] public PlanApplicableFor ApplicableFor { get; set; } @@ -69,6 +72,9 @@ public class Plan [Required] public bool Active { get; set; } + /// + /// Indicates whether this plan is shown in your (operator's) app only, or in the Monta app as well. + /// [Required] public PlanApplicationAudience ApplicationAudience { get; set; } @@ -78,6 +84,9 @@ public class Plan [Required] public bool VisibleInMarketPlace { get; set; } + /// + /// Indicates if the price is per charge point or a fixed price. + /// [Required] public PlanPriceModel PriceModel { get; set; } @@ -93,9 +102,15 @@ public class Plan [Required] public bool PricesWithVat { get; set; } + /// + /// Plan service type, custom or tax-refund. + /// [Required] public PlanServiceType ServiceType { get; set; } + /// + /// Additional configuration, based on serviceType. + /// [Required] public PlanServiceConfig ServiceConfig { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/PlanPrice.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/PlanPrice.verified.cs index 93023eed6..1a9c0fc42 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/PlanPrice.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Plans/PlanPrice.verified.cs @@ -22,8 +22,11 @@ public class PlanPrice /// public double Price { get; set; } + /// + /// Currency for `price`. + /// [Required] - public Currency Currency { get; set; } + public Currency1 Currency { get; set; } /// public override string ToString() diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateAdditionalPricingDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateAdditionalPricingDto.verified.cs index 0970ce4bf..97b955c0f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateAdditionalPricingDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateAdditionalPricingDto.verified.cs @@ -12,6 +12,9 @@ namespace Monta.ApiClient.Generated.Contracts.PriceGroups; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class CreateAdditionalPricingDto { + /// + /// Type of the additional pricing. `absolute` means the value is a price. + /// [Required] public AdditionalPricingType Type { get; set; } @@ -19,9 +22,15 @@ public class CreateAdditionalPricingDto /// The value of this additional pricing. /// [Required] + [Range(0, double.MaxValue)] public double Value { get; set; } + /// + /// A title for this additional pricing. + /// + public string? Title { get; set; } + /// public override string ToString() - => $"{nameof(Type)}: ({Type}), {nameof(Value)}: {Value}"; + => $"{nameof(Type)}: ({Type}), {nameof(Value)}: {Value}, {nameof(Title)}: {Title}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateOrUpdatePriceGroupDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateOrUpdatePriceGroupDto.verified.cs index f045adabc..8342eb8eb 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateOrUpdatePriceGroupDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateOrUpdatePriceGroupDto.verified.cs @@ -25,9 +25,15 @@ public class CreateOrUpdatePriceGroupDto [Required] public string Name { get; set; } + /// + /// Type of the price group. + /// [Required] public PriceGroupType Type { get; set; } + /// + /// The master price. + /// [Required] public CreateOrUpdatePricingDto MasterPrice { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateOrUpdatePricingDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateOrUpdatePricingDto.verified.cs index 4af26f7d1..12aec7c6f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateOrUpdatePricingDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/PriceGroups/CreateOrUpdatePricingDto.verified.cs @@ -17,6 +17,9 @@ public class CreateOrUpdatePricingDto /// public string? Description { get; set; } + /// + /// Type of the pricing. `minute` is used for Minute fee. `min` is used for the master price. + /// [Required] public PricingType Type { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Prices/Currency17.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Prices/Currency17.verified.cs new file mode 100644 index 000000000..ebc3544f6 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Prices/Currency17.verified.cs @@ -0,0 +1,35 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Prices; + +/// +/// Currency17. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Currency17 +{ + /// + /// Currency identifier, e.g. dkk. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Readable name of currency. + /// + [Required] + public string Name { get; set; } + + /// + /// Number of decimals for this currency. + /// + public int Decimals { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Prices/PricesForecast.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Prices/PricesForecast.verified.cs index ceb96fb4d..ea3c874bd 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Prices/PricesForecast.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Prices/PricesForecast.verified.cs @@ -12,12 +12,21 @@ namespace Monta.ApiClient.Generated.Contracts.Prices; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class PricesForecast { + /// + /// The operator to which this charge point and price group belongs to. + /// [Required] public Operator Operator { get; set; } + /// + /// The currency applicable for this forecast. + /// [Required] - public Currency Currency { get; set; } + public Currency17 Currency { get; set; } + /// + /// The price group applicable for this forecast. + /// [Required] public PriceGroup PriceGroup { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/MontaPageReportDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/MontaPageReportDto.verified.cs new file mode 100644 index 000000000..8e29ee7ce --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/MontaPageReportDto.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Reports; + +/// +/// MontaPageReportDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class MontaPageReportDto +{ + [Required] + public List Data { get; set; } + + [Required] + public MontaPageMeta Meta { get; set; } + + /// + public override string ToString() + => $"{nameof(Data)}.Count: {Data?.Count ?? 0}, {nameof(Meta)}: ({Meta})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/ReasonDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/ReasonDto.verified.cs new file mode 100644 index 000000000..1641d5f07 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/ReasonDto.verified.cs @@ -0,0 +1,48 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Reports; + +/// +/// ReasonDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ReasonDto +{ + /// + /// Id of the reason. + /// + [Required] + public int Id { get; set; } + + /// + /// Identifier of the reason. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Reason of the report. + /// + [Required] + public string Reason { get; set; } + + /// + /// Type of the report. + /// + [Required] + public string Type { get; set; } + + /// + /// Priority of the report. + /// + [Required] + public string Priority { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(Identifier)}: {Identifier}, {nameof(Reason)}: {Reason}, {nameof(Type)}: {Type}, {nameof(Priority)}: {Priority}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/ReportDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/ReportDto.verified.cs new file mode 100644 index 000000000..b24a83e73 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/ReportDto.verified.cs @@ -0,0 +1,135 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Reports; + +/// +/// ReportDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class ReportDto +{ + /// + /// Id of the report. + /// + [Required] + public long Id { get; set; } + + /// + /// Id of the user who reported. + /// + public long? ReportedByUserId { get; set; } + + /// + /// Id of the operator related to the report. + /// + [Required] + public long OperatorId { get; set; } + + /// + /// Type of the relation. + /// + [Required] + public string RelationType { get; set; } + + /// + /// Id of the relation. + /// + [Required] + public long RelationId { get; set; } + + /// + /// Body of the report. + /// + public string? Body { get; set; } + + /// + /// State of the report. + /// + [Required] + public string State { get; set; } + + /// + /// Reason of the report. + /// + public ReasonDto? Reason { get; set; } + + /// + /// Source of the report. + /// + public string? Source { get; set; } + + /// + /// List of image URLs. + /// + [Required] + public List ImageUrls { get; set; } + + /// + /// Id of the operator assigned to the report. + /// + public long? AssignedToOperatorId { get; set; } + + /// + /// Id of the user assigned to the report. + /// + public long? AssignedToUserId { get; set; } + + /// + /// Id of the user who resolved the report. + /// + public long? ResolvedByUserId { get; set; } + + /// + /// Note from the operator. + /// + public string? OperatorNote { get; set; } + + /// + /// Note from the admin. + /// + public string? AdminNote { get; set; } + + /// + /// Note from the user. + /// + public string? UserNote { get; set; } + + /// + /// Time when the report was resolved. + /// + public DateTimeOffset? ResolvedAt { get; set; } + + /// + /// Time when the report was escalated. + /// + public DateTimeOffset? EscalatedAt { get; set; } + + /// + /// Time when the report was assigned. + /// + public DateTimeOffset? AssignedAt { get; set; } + + /// + /// Time when the report was created. + /// + [Required] + public DateTimeOffset CreatedAt { get; set; } + + /// + /// Time when the report was updated. + /// + public DateTimeOffset? UpdatedAt { get; set; } + + /// + /// Time when the report was deleted. + /// + public DateTimeOffset? DeletedAt { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(ReportedByUserId)}: {ReportedByUserId}, {nameof(OperatorId)}: {OperatorId}, {nameof(RelationType)}: {RelationType}, {nameof(RelationId)}: {RelationId}, {nameof(Body)}: {Body}, {nameof(State)}: {State}, {nameof(Reason)}: ({Reason}), {nameof(Source)}: {Source}, {nameof(ImageUrls)}.Count: {ImageUrls?.Count ?? 0}, {nameof(AssignedToOperatorId)}: {AssignedToOperatorId}, {nameof(AssignedToUserId)}: {AssignedToUserId}, {nameof(ResolvedByUserId)}: {ResolvedByUserId}, {nameof(OperatorNote)}: {OperatorNote}, {nameof(AdminNote)}: {AdminNote}, {nameof(UserNote)}: {UserNote}, {nameof(ResolvedAt)}: ({ResolvedAt}), {nameof(EscalatedAt)}: ({EscalatedAt}), {nameof(AssignedAt)}: ({AssignedAt}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/RequestParameters/GetReportParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/RequestParameters/GetReportParameters.verified.cs new file mode 100644 index 000000000..0d2099bdb --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/RequestParameters/GetReportParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Reports; + +/// +/// Parameters for operation request. +/// Description: Retrieve a report related to a charge point. +/// Operation: GetReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetReportParameters +{ + [Required] + public long ReportId { get; set; } + + /// + public override string ToString() + => $"{nameof(ReportId)}: {ReportId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/RequestParameters/GetReportsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/RequestParameters/GetReportsParameters.verified.cs new file mode 100644 index 000000000..55857df0e --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Reports/RequestParameters/GetReportsParameters.verified.cs @@ -0,0 +1,40 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Reports; + +/// +/// Parameters for operation request. +/// Description: Retrieve a list of reports for charge point(s). +/// Operation: GetReports. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetReportsParameters +{ + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + + public long? ChargePointId { get; set; } + + public string? State { get; set; } + + public DateTimeOffset? FromDate { get; set; } + + public DateTimeOffset? ToDate { get; set; } + + public string? Priority { get; set; } + + /// + public override string ToString() + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(ChargePointId)}: {ChargePointId}, {nameof(State)}: {State}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(Priority)}: {Priority}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/CreateSite.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/CreateSite.verified.cs index 1702f728a..39aed0eb9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/CreateSite.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/CreateSite.verified.cs @@ -25,9 +25,15 @@ public class CreateSite [MinLength(1)] public string Name { get; set; } + /// + /// Address of the site, Note: please ensure to always provide a valid address. + /// [Required] public CreatedOrUpdateAddress Address { get; set; } + /// + /// Visibility type of the site. + /// [Required] public VisibilityType1 Visibility { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/PatchSite.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/PatchSite.verified.cs index 6eb2a1466..e830f1c6b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/PatchSite.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/PatchSite.verified.cs @@ -17,8 +17,14 @@ public class PatchSite /// public string? Name { get; set; } + /// + /// Address of the site, Note: please ensure to always provide a valid address. + /// public CreatedOrUpdateAddress? Address { get; set; } + /// + /// Visibility type of the site. + /// public VisibilityType3? Visibility { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/RequestParameters/GetSitesParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/RequestParameters/GetSitesParameters.verified.cs index 41439f011..16e5c1cf5 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/RequestParameters/GetSitesParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/RequestParameters/GetSitesParameters.verified.cs @@ -24,28 +24,20 @@ public class GetSitesParameters /// public int PerPage { get; set; } = 10; - /// - /// The team id from which sites will be filtered by. - /// - public long TeamId { get; set; } + public long? TeamId { get; set; } - /// - /// Filter sites by partnerExternalId, to filter only resources without `partnerExternalId` *use* `partnerExternalId=""`. - /// - public string PartnerExternalId { get; set; } + public string? PartnerExternalId { get; set; } - /// - /// lat,long coordinates. If supplied, the Charge Points will be sorted in nearest first order relative - /// to this point. (Format: 55.7096,12.5856). - /// - public string SortByLocation { get; set; } + [RegularExpression("^(-?\\d*\\.\\d+|\\d+\\.\\d*)(,)(-?\\d*\\.\\d+|\\d+\\.\\d*)$")] + public string? SortByLocation { get; set; } + + public long? OperatorId { get; set; } + + public bool IncludePublic { get; set; } = false; - /// - /// Includes deleted resources in the response. - /// public bool IncludeDeleted { get; set; } = false; /// public override string ToString() - => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(SortByLocation)}: {SortByLocation}, {nameof(IncludeDeleted)}: {IncludeDeleted}"; + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(SortByLocation)}: {SortByLocation}, {nameof(OperatorId)}: {OperatorId}, {nameof(IncludePublic)}: {IncludePublic}, {nameof(IncludeDeleted)}: {IncludeDeleted}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/Site.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/Site.verified.cs index 0ac165369..a762ee5ec 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/Site.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Sites/Site.verified.cs @@ -38,6 +38,9 @@ public class Site [Required] public string Name { get; set; } + /// + /// Operator of this charging site. + /// public Operator? Operator { get; set; } /// @@ -93,6 +96,9 @@ public class Site /// public string? Note { get; set; } + /// + /// Location information for this site. + /// [Required] public Location Location { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/CreateSponsoredChargePointDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/CreateSponsoredChargePointDto.verified.cs index de51b9575..6fda98029 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/CreateSponsoredChargePointDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/CreateSponsoredChargePointDto.verified.cs @@ -36,6 +36,9 @@ public class CreateSponsoredChargePointDto [Range(0, int.MaxValue)] public long? PriceGroupId { get; set; } + /// + /// The payout schedule for this sponsored charge point. + /// [Required] public SponsoredChargePointPayoutType PayoutSchedule { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/PatchSponsoredChargePoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/PatchSponsoredChargePoint.verified.cs index 3e5cb0692..7fa989b80 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/PatchSponsoredChargePoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/PatchSponsoredChargePoint.verified.cs @@ -17,6 +17,9 @@ public class PatchSponsoredChargePoint /// public long? PriceGroupId { get; set; } + /// + /// The payout schedule for this sponsored charge point. + /// public SponsoredChargePointPayoutType? PayoutSchedule { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/PublicUser1.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/PublicUser1.verified.cs new file mode 100644 index 000000000..3062ac2f7 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/PublicUser1.verified.cs @@ -0,0 +1,30 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.SponsoredChargePoints; + +/// +/// PublicUser1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PublicUser1 +{ + /// + /// Id of the user. + /// + [Required] + public long Id { get; set; } + + /// + /// Formatted name to be displayed. + /// + [Required] + public string DisplayName { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(DisplayName)}: {DisplayName}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/SponsoredChargePoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/SponsoredChargePoint.verified.cs index d16c0cdec..95bc2ff23 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/SponsoredChargePoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/SponsoredChargePoint.verified.cs @@ -22,6 +22,9 @@ public class SponsoredChargePoint /// public long TeamId { get; set; } + /// + /// The payout frequency for this sponsored charge point. + /// [Required] public SponsoredChargePointPayoutType Payout { get; set; } @@ -30,8 +33,14 @@ public class SponsoredChargePoint /// public bool PayForSubscriptions { get; set; } + /// + /// Operator of this sponsored charge point. + /// public Operator? Operator { get; set; } + /// + /// The charge point being sponsored. + /// [Required] public SponsoredChargePointData ChargePoint { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/SponsoredChargePointData.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/SponsoredChargePointData.verified.cs index 7d541ac98..01f3645f9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/SponsoredChargePointData.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SponsoredChargePoints/SponsoredChargePointData.verified.cs @@ -22,10 +22,19 @@ public class SponsoredChargePointData /// public string? Name { get; set; } - public PublicUser? User { get; set; } + /// + /// The user (owner) of this charge point. + /// + public PublicUser1? User { get; set; } + /// + /// The sponsored price group of this charge point. + /// public PriceGroup? SponsoredPriceGroup { get; set; } + /// + /// Location information for this charge point. + /// [Required] public Location Location { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SubscriptionPurchases/Currency3.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SubscriptionPurchases/Currency3.verified.cs new file mode 100644 index 000000000..01b772bb2 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SubscriptionPurchases/Currency3.verified.cs @@ -0,0 +1,35 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.SubscriptionPurchases; + +/// +/// Currency3. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Currency3 +{ + /// + /// Currency identifier, e.g. dkk. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Readable name of currency. + /// + [Required] + public string Name { get; set; } + + /// + /// Number of decimals for this currency. + /// + public int Decimals { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SubscriptionPurchases/SubscriptionPurchase.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SubscriptionPurchases/SubscriptionPurchase.verified.cs index 984c54c7c..1a3486e82 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SubscriptionPurchases/SubscriptionPurchase.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/SubscriptionPurchases/SubscriptionPurchase.verified.cs @@ -22,6 +22,9 @@ public class SubscriptionPurchase /// public string? Note { get; set; } + /// + /// The type of this subscription purchase. + /// [Required] public SubscriptionPurchaseTypeDto Type { get; set; } @@ -50,9 +53,15 @@ public class SubscriptionPurchase /// public double TotalAmount { get; set; } + /// + /// The currency for this purchase. + /// [Required] - public Currency Currency { get; set; } + public Currency3 Currency { get; set; } + /// + /// The subscription this purchase refers to. + /// [Required] public Subscription Subscription { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Subscriptions/CreateSubscription.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Subscriptions/CreateSubscription.verified.cs index e8b439301..de23a290f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Subscriptions/CreateSubscription.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Subscriptions/CreateSubscription.verified.cs @@ -18,15 +18,18 @@ public class CreateSubscription [Range(0, int.MaxValue)] public long PlanId { get; set; } - [Required] - public SubscriptionCustomerType CustomerType { get; set; } - /// - /// Id of the customer the subscription is created for, e.g. a chargePointId. + /// Id of the customer the subscription is created for, e.g. team or charge-point id. /// [Range(0, int.MaxValue)] public long CustomerId { get; set; } + /// + /// Type of the customer that the subscription is created for. e.g. team or charge-point. + /// + [Required] + public SubscriptionCustomerType CustomerType { get; set; } + /// /// Allows to modify the absolute discount on a subscription if provided. /// If not provided, the discount of the plan is used. @@ -41,9 +44,18 @@ public class CreateSubscription /// public double? DiscountPercentage { get; set; } + /// + /// Configure the subscription, based on the plans serviceType.Currently you can configure tax-refund subscriptions only. + /// public SubscriptionServiceConfig? ServiceConfig { get; set; } + /// + /// The user that should be assigned as the purchaser of the subscription. If not provided, the subscription will be assigned to the default user for this consumer. + /// + [Range(0, int.MaxValue)] + public long? UserId { get; set; } + /// public override string ToString() - => $"{nameof(PlanId)}: {PlanId}, {nameof(CustomerType)}: ({CustomerType}), {nameof(CustomerId)}: {CustomerId}, {nameof(DiscountAbsolute)}: {DiscountAbsolute}, {nameof(DiscountPercentage)}: {DiscountPercentage}, {nameof(ServiceConfig)}: ({ServiceConfig})"; + => $"{nameof(PlanId)}: {PlanId}, {nameof(CustomerId)}: {CustomerId}, {nameof(CustomerType)}: ({CustomerType}), {nameof(DiscountAbsolute)}: {DiscountAbsolute}, {nameof(DiscountPercentage)}: {DiscountPercentage}, {nameof(ServiceConfig)}: ({ServiceConfig}), {nameof(UserId)}: {UserId}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Subscriptions/RequestParameters/GetSubscriptionsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Subscriptions/RequestParameters/GetSubscriptionsParameters.verified.cs index f27899cb6..70fc08169 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Subscriptions/RequestParameters/GetSubscriptionsParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Subscriptions/RequestParameters/GetSubscriptionsParameters.verified.cs @@ -28,9 +28,13 @@ public class GetSubscriptionsParameters public long? ChargePointId { get; set; } + public long? CustomerId { get; set; } + + public SubscriptionCustomerType? CustomerType { get; set; } + public long? SubscriptionPurchaseId { get; set; } /// public override string ToString() - => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(PlanId)}: {PlanId}, {nameof(ChargePointId)}: {ChargePointId}, {nameof(SubscriptionPurchaseId)}: {SubscriptionPurchaseId}"; + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(PlanId)}: {PlanId}, {nameof(ChargePointId)}: {ChargePointId}, {nameof(CustomerId)}: {CustomerId}, {nameof(CustomerType)}: ({CustomerType}), {nameof(SubscriptionPurchaseId)}: {SubscriptionPurchaseId}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/RequestParameters/CreateTariffPeriodGroupParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/RequestParameters/CreateTariffPeriodGroupParameters.verified.cs index a34cd03c2..eb227dc2e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/RequestParameters/CreateTariffPeriodGroupParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/RequestParameters/CreateTariffPeriodGroupParameters.verified.cs @@ -15,7 +15,7 @@ namespace Monta.ApiClient.Generated.Contracts.TariffPeriodGroups; public class CreateTariffPeriodGroupParameters { [Required] - public TariffPeriodGroup Request { get; set; } + public TariffPeriodGroup1 Request { get; set; } /// public override string ToString() diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/RequestParameters/UpdateTariffPeriodGroupParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/RequestParameters/UpdateTariffPeriodGroupParameters.verified.cs index b3df17d51..904e15de6 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/RequestParameters/UpdateTariffPeriodGroupParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/RequestParameters/UpdateTariffPeriodGroupParameters.verified.cs @@ -18,7 +18,7 @@ public class UpdateTariffPeriodGroupParameters public long Id { get; set; } [Required] - public TariffPeriodGroup Request { get; set; } + public TariffPeriodGroup2 Request { get; set; } /// public override string ToString() diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/TariffPeriodGroup1.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/TariffPeriodGroup1.verified.cs new file mode 100644 index 000000000..95cdd5289 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/TariffPeriodGroup1.verified.cs @@ -0,0 +1,41 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TariffPeriodGroups; + +/// +/// TariffPeriodGroup1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class TariffPeriodGroup1 +{ + /// + /// tariff period group active from date. + /// + [Required] + public DateTimeOffset ActiveFrom { get; set; } + + /// + /// tariff period group active to date. + /// + [Required] + public DateTimeOffset ActiveTo { get; set; } + + /// + /// tariff period group description. + /// + [Required] + public string Description { get; set; } + + /// + /// tariff id. + /// + public long TariffId { get; set; } + + /// + public override string ToString() + => $"{nameof(ActiveFrom)}: ({ActiveFrom}), {nameof(ActiveTo)}: ({ActiveTo}), {nameof(Description)}: {Description}, {nameof(TariffId)}: {TariffId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/TariffPeriodGroup2.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/TariffPeriodGroup2.verified.cs new file mode 100644 index 000000000..f7a8067ea --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffPeriodGroups/TariffPeriodGroup2.verified.cs @@ -0,0 +1,33 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TariffPeriodGroups; + +/// +/// TariffPeriodGroup2. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class TariffPeriodGroup2 +{ + /// + /// tariff period group active from date. + /// + public DateTimeOffset? ActiveFrom { get; set; } + + /// + /// tariff period group active to date. + /// + public DateTimeOffset? ActiveTo { get; set; } + + /// + /// tariff period group description. + /// + public string? Description { get; set; } + + /// + public override string ToString() + => $"{nameof(ActiveFrom)}: ({ActiveFrom}), {nameof(ActiveTo)}: ({ActiveTo}), {nameof(Description)}: {Description}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriod.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriod.verified.cs index fd8f01bb8..19d8ddb97 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriod.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriod.verified.cs @@ -22,9 +22,15 @@ public class TariffRecurringPeriod /// public long TariffId { get; set; } + /// + /// day of the period. + /// [Required] public DayOfWeek DayOfWeek { get; set; } + /// + /// End day of the period. + /// public DayOfWeek? EndDayOfWeek { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriodCreateRequestDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriodCreateRequestDto.verified.cs index 08ffcbb4a..06444044f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriodCreateRequestDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriodCreateRequestDto.verified.cs @@ -24,9 +24,15 @@ public class TariffRecurringPeriodCreateRequestDto [Required] public long GroupId { get; set; } + /// + /// Capitalized name of the day of the week. + /// [Required] public DayOfWeek DayOfWeek { get; set; } + /// + /// Capitalized name of the day of the week that the price is for. + /// public DayOfWeek? EndDayOfWeek { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriodUpdateRequestDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriodUpdateRequestDto.verified.cs index d5fb1defb..d691db0dd 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriodUpdateRequestDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TariffRecurringPeriods/TariffRecurringPeriodUpdateRequestDto.verified.cs @@ -12,8 +12,14 @@ namespace Monta.ApiClient.Generated.Contracts.TariffRecurringPeriods; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class TariffRecurringPeriodUpdateRequestDto { + /// + /// Capitalized name of the day of the week. + /// public DayOfWeek? DayOfWeek { get; set; } + /// + /// Capitalized name of the end day of the week. + /// public DayOfWeek? EndDayOfWeek { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/CreateTariffRequest.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/CreateTariffRequest.verified.cs index d70a46cc9..892f5b510 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/CreateTariffRequest.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/CreateTariffRequest.verified.cs @@ -64,6 +64,9 @@ public class CreateTariffRequest [Required] public List ZipCodes { get; set; } + /// + /// Dynamic or weekly. + /// public TariffType TariffType { get; set; } /// @@ -83,6 +86,9 @@ public class CreateTariffRequest [Required] public string Area { get; set; } + /// + /// What kind of customer types are the tariff for?. + /// public TariffCustomerType? CustomerType { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/FullTariff.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/FullTariff.verified.cs index be711f889..d3e79b77e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/FullTariff.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/FullTariff.verified.cs @@ -12,6 +12,9 @@ namespace Monta.ApiClient.Generated.Contracts.Tariffs; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class FullTariff { + /// + /// tariff. + /// [Required] public TariffDto Tariff { get; set; } @@ -21,6 +24,9 @@ public class FullTariff [Required] public List Prices { get; set; } + /// + /// Price specification. + /// public PriceSpecification? PriceSpecification { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/TariffDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/TariffDto.verified.cs index c4ccbaaf6..f0fdc4f1f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/TariffDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/TariffDto.verified.cs @@ -71,6 +71,9 @@ public class TariffDto [Required] public List ZipCodes { get; set; } + /// + /// Type of the tariff. + /// [Required] public TariffType TariffType { get; set; } @@ -91,6 +94,9 @@ public class TariffDto [Required] public string Area { get; set; } + /// + /// Customer type of the tariff. + /// public TariffCustomerType? CustomerType { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/UpdateTariffRequest.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/UpdateTariffRequest.verified.cs index 376283ab9..e5c771eb8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/UpdateTariffRequest.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Tariffs/UpdateTariffRequest.verified.cs @@ -63,6 +63,9 @@ public class UpdateTariffRequest /// public List? ZipCodes { get; set; } = new List(); + /// + /// Dynamic or weekly. + /// public TariffType? TariffType { get; set; } /// @@ -83,6 +86,9 @@ public class UpdateTariffRequest [Required] public string Area { get; set; } + /// + /// What kind of customer types are the tariff for?. + /// public TariffCustomerType? CustomerType { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/CreateTeamMemberProfile.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/CreateTeamMemberProfile.verified.cs new file mode 100644 index 000000000..42fe17dc0 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/CreateTeamMemberProfile.verified.cs @@ -0,0 +1,89 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// CreateTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class CreateTeamMemberProfile +{ + /// + /// Id of the team. + /// + [Range(0, int.MaxValue)] + public long TeamId { get; set; } + + /// + /// The team member profile name. + /// + [Required] + public string Name { get; set; } + + /// + /// The team member profile description. + /// + [Required] + public string Description { get; set; } + + /// + /// Role for team member profile. + /// + [Required] + public TeamMemberRole Role { get; set; } + + /// + /// The price group, when not provided the default team price group will be applied. + /// + public long? PriceGroupId { get; set; } + + /// + /// The cost group. + /// + public long? CostGroupId { get; set; } + + /// + /// Allows the team applying member profile to configure charge points. + /// + public bool CanConfigureChargePoints { get; set; } = false; + + /// + /// Gives the team applying member profile access to pay with team wallet when charging. + /// + public bool CanPayWithTeamWallet { get; set; } = false; + + /// + /// Allows the team applying member profile to request sponsoring from this team for their charge point. + /// + public bool CanRequestSponsoring { get; set; } = false; + + /// + /// Allows the team applying member profile to view and manage other members settings. + /// + public bool CanManageTeamMembers { get; set; } = false; + + /// + /// Who can pay the charging with Wallet?. + /// + [Required] + public TeamWalletChargePaymentType TeamWalletChargePaymentType { get; set; } = TeamWalletChargePaymentType.None; + + /// + /// Gives the team member access to withdraw and deposit from your team wallet to your bank account. + /// + public bool CanManageTeamWallet { get; set; } = false; + + /// + /// List of country ids for which the team member can pay for charges. + /// + [Required] + public List CanPayForChargesCountryIds { get; set; } + + /// + public override string ToString() + => $"{nameof(TeamId)}: {TeamId}, {nameof(Name)}: {Name}, {nameof(Description)}: {Description}, {nameof(Role)}: ({Role}), {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CostGroupId)}: {CostGroupId}, {nameof(CanConfigureChargePoints)}: {CanConfigureChargePoints}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(TeamWalletChargePaymentType)}: {TeamWalletChargePaymentType}, {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(CanPayForChargesCountryIds)}.Count: {CanPayForChargesCountryIds?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/MontaPageTeamMemberProfileDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/MontaPageTeamMemberProfileDto.verified.cs new file mode 100644 index 000000000..a4aea7ecd --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/MontaPageTeamMemberProfileDto.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// MontaPageTeamMemberProfileDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class MontaPageTeamMemberProfileDto +{ + [Required] + public List Data { get; set; } + + [Required] + public MontaPageMeta Meta { get; set; } + + /// + public override string ToString() + => $"{nameof(Data)}.Count: {Data?.Count ?? 0}, {nameof(Meta)}: ({Meta})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/PatchTeamMemberProfile.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/PatchTeamMemberProfile.verified.cs new file mode 100644 index 000000000..74287bb96 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/PatchTeamMemberProfile.verified.cs @@ -0,0 +1,75 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// PatchTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PatchTeamMemberProfile +{ + /// + /// Name for the team member profile. + /// + public string? Name { get; set; } + + /// + /// Description for the team member profile. + /// + public string? Description { get; set; } + + /// + /// Role for the team member profile. + /// + public TeamMemberRole? Role { get; set; } + + /// + /// The price group for the team member profile. + /// + public long? PriceGroupId { get; set; } + + /// + /// The cost group for the team member profile. + /// + public long? CostGroupId { get; set; } + + /// + /// Gives the team member access to pay with team wallet when charging. + /// + public bool? CanPayWithTeamWallet { get; set; } = false; + + /// + /// Gives the team member access to withdraw and deposit from your team wallet to your bank account. + /// + public bool? CanManageTeamWallet { get; set; } = false; + + /// + /// Allows the team member to request sponsoring from this team for their charge point. + /// + public bool? CanRequestSponsoring { get; set; } = false; + + /// + /// Allows the team member to view and manage other members settings. + /// + public bool? CanManageTeamMembers { get; set; } = false; + + public TeamWalletChargePaymentType? TeamWalletChargePaymentType { get; set; } + + /// + /// Allows the team member profile to configure charge points. + /// + public bool? CanConfigureChargePoints { get; set; } = false; + + /// + /// List of country ids for which the team member can pay for charges. + /// + public List? CanPayForChargesCountryIds { get; set; } = new List(); + + /// + public override string ToString() + => $"{nameof(Name)}: {Name}, {nameof(Description)}: {Description}, {nameof(Role)}: ({Role}), {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CostGroupId)}: {CostGroupId}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(TeamWalletChargePaymentType)}: ({TeamWalletChargePaymentType}), {nameof(CanConfigureChargePoints)}: {CanConfigureChargePoints}, {nameof(CanPayForChargesCountryIds)}.Count: {CanPayForChargesCountryIds?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/DeleteTeamMemberProfileParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/DeleteTeamMemberProfileParameters.verified.cs new file mode 100644 index 000000000..b1d74ab2b --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/DeleteTeamMemberProfileParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// Parameters for operation request. +/// Description: Delete an existing team member profile. +/// Operation: DeleteTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class DeleteTeamMemberProfileParameters +{ + [Required] + public long Id { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/GetTeamMemberProfileParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/GetTeamMemberProfileParameters.verified.cs new file mode 100644 index 000000000..eeadddf67 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/GetTeamMemberProfileParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// Parameters for operation request. +/// Description: Retrieve a team member profile by id. +/// Operation: GetTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetTeamMemberProfileParameters +{ + [Required] + public long Id { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/GetTeamMemberProfilesParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/GetTeamMemberProfilesParameters.verified.cs new file mode 100644 index 000000000..f2cc5d79a --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/GetTeamMemberProfilesParameters.verified.cs @@ -0,0 +1,34 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// Parameters for operation request. +/// Description: Retrieve a list of team member profiles. +/// Operation: GetTeamMemberProfiles. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetTeamMemberProfilesParameters +{ + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + + public long? TeamId { get; set; } + + public string? Name { get; set; } + + /// + public override string ToString() + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(Name)}: {Name}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/PostTeamMemberProfileParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/PostTeamMemberProfileParameters.verified.cs new file mode 100644 index 000000000..69a4f5139 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/PostTeamMemberProfileParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// Parameters for operation request. +/// Description: Create a team member profile. +/// Operation: PostTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PostTeamMemberProfileParameters +{ + [Required] + public CreateTeamMemberProfile Request { get; set; } + + /// + public override string ToString() + => $"{nameof(Request)}: ({Request})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/UpdateTeamMemberProfileParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/UpdateTeamMemberProfileParameters.verified.cs new file mode 100644 index 000000000..fce06436f --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/RequestParameters/UpdateTeamMemberProfileParameters.verified.cs @@ -0,0 +1,26 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// Parameters for operation request. +/// Description: Patch a team member profile. +/// Operation: UpdateTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UpdateTeamMemberProfileParameters +{ + [Required] + public long Id { get; set; } + + [Required] + public PatchTeamMemberProfile Request { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(Request)}: ({Request})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/TeamMemberProfile.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/TeamMemberProfile.verified.cs new file mode 100644 index 000000000..21e38336f --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMemberProfiles/TeamMemberProfile.verified.cs @@ -0,0 +1,112 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; + +/// +/// TeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class TeamMemberProfile +{ + /// + /// Id of the team member profile. + /// + [Required] + public long Id { get; set; } + + /// + /// Team id of team member profile. + /// + public long TeamId { get; set; } + + /// + /// The team member profile name. + /// + [Required] + public string Name { get; set; } + + /// + /// The team member profile description. + /// + public string? Description { get; set; } + + /// + /// Role of the this team member profile. + /// + [Required] + public TeamMemberRole Role { get; set; } + + /// + /// The price group for this team member profile. + /// + public long? PriceGroupId { get; set; } + + /// + /// The cost group for this team member profile. + /// + public long? CostGroupId { get; set; } + + /// + /// Indicates if the team member profile access to pay with team wallet when charging. + /// + public bool CanPayWithTeamWallet { get; set; } = false; + + /// + /// Indicates if team member profile has access to withdraw and deposit from your team wallet to your bank account. + /// + public bool CanManageTeamWallet { get; set; } = false; + + /// + /// Indicates if the team member profile is allowed to request sponsoring from this team for their charge point. + /// + public bool CanRequestSponsoring { get; set; } = false; + + /// + /// Indicates that the team member profile can view and manage other members settings. + /// + public bool CanManageTeamMembers { get; set; } = false; + + /// + /// Indicates that the team member profile can configure charge points. + /// + public bool CanConfigureChargePoints { get; set; } = false; + + /// + /// Who can pay the charging with Wallet?. + /// + [Required] + public TeamWalletChargePaymentType TeamWalletChargePaymentType { get; set; } = TeamWalletChargePaymentType.None; + + /// + /// List of country ids for which the team member can pay for charges. + /// + public List? CanPayForChargesCountryIds { get; set; } = new List(); + + /// + /// Operator of this team member. + /// + public Operator? Operator { get; set; } + + /// + /// Date the team member profile was created. + /// + public DateTimeOffset? CreatedAt { get; set; } + + /// + /// Date the team member profile was updated. + /// + public DateTimeOffset? UpdatedAt { get; set; } + + /// + /// Date the team member profile was deleted. + /// + public DateTimeOffset? DeletedAt { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(TeamId)}: {TeamId}, {nameof(Name)}: {Name}, {nameof(Description)}: {Description}, {nameof(Role)}: ({Role}), {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CostGroupId)}: {CostGroupId}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(CanConfigureChargePoints)}: {CanConfigureChargePoints}, {nameof(TeamWalletChargePaymentType)}: {TeamWalletChargePaymentType}, {nameof(CanPayForChargesCountryIds)}.Count: {CanPayForChargesCountryIds?.Count ?? 0}, {nameof(Operator)}: ({Operator}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/CreateTeamMember.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/CreateTeamMember.verified.cs index e1e24e4dc..27e932b26 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/CreateTeamMember.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/CreateTeamMember.verified.cs @@ -39,6 +39,9 @@ public class CreateTeamMember [RegularExpression("^\\+[1-9]\\d{1,14}$")] public string? Phone { get; set; } + /// + /// Role for this member within the team. + /// [Required] public TeamMemberRole Role { get; set; } @@ -47,6 +50,21 @@ public class CreateTeamMember /// public long? PriceGroupId { get; set; } + /// + /// The cost group for this team member. + /// + public long? CostGroupId { get; set; } + + /// + /// The team member profile id to apply to this team member. + /// + public long? TeamMemberProfileId { get; set; } + + /// + /// Indicates if the team member access to pay with team wallet when charging. + /// + public bool CanConfigureChargePoints { get; set; } = false; + /// /// Gives the team member access to pay with team wallet when charging. /// @@ -69,6 +87,11 @@ public class CreateTeamMember /// public bool CanManageTeamWallet { get; set; } = false; + /// + /// List of country ids for which the team member can pay for charges. + /// + public List? CanPayForChargesCountryIds { get; set; } = new List(); + /// /// A note for the team member. /// @@ -91,5 +114,5 @@ public class CreateTeamMember /// public override string ToString() - => $"{nameof(TeamId)}: {TeamId}, {nameof(UserId)}: {UserId}, {nameof(Email)}: {Email}, {nameof(Phone)}: {Phone}, {nameof(Role)}: ({Role}), {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(TeamWalletChargePaymentType)}: ({TeamWalletChargePaymentType}), {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(Note)}: {Note}, {nameof(ChargePointIds)}.Count: {ChargePointIds?.Count ?? 0}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; + => $"{nameof(TeamId)}: {TeamId}, {nameof(UserId)}: {UserId}, {nameof(Email)}: {Email}, {nameof(Phone)}: {Phone}, {nameof(Role)}: ({Role}), {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CostGroupId)}: {CostGroupId}, {nameof(TeamMemberProfileId)}: {TeamMemberProfileId}, {nameof(CanConfigureChargePoints)}: {CanConfigureChargePoints}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(TeamWalletChargePaymentType)}: ({TeamWalletChargePaymentType}), {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(CanPayForChargesCountryIds)}.Count: {CanPayForChargesCountryIds?.Count ?? 0}, {nameof(Note)}: {Note}, {nameof(ChargePointIds)}.Count: {ChargePointIds?.Count ?? 0}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/MontaPageTeamMemberDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/MontaPageTeamMemberDto.verified.cs index cdf1d4493..b0413e1bb 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/MontaPageTeamMemberDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/MontaPageTeamMemberDto.verified.cs @@ -13,7 +13,7 @@ namespace Monta.ApiClient.Generated.Contracts.TeamMembers; public class MontaPageTeamMemberDto { [Required] - public List Data { get; set; } + public List Data { get; set; } [Required] public MontaPageMeta Meta { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/PatchTeamMember.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/PatchTeamMember.verified.cs index 834bf5de8..c89c2355f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/PatchTeamMember.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/PatchTeamMember.verified.cs @@ -17,6 +17,9 @@ public class PatchTeamMember /// public List? ChargePointIds { get; set; } = new List(); + /// + /// Role for this member within the team. + /// public TeamMemberRole? Role { get; set; } /// @@ -24,6 +27,21 @@ public class PatchTeamMember /// public long? PriceGroupId { get; set; } + /// + /// The cost group for this team member. + /// + public long? CostGroupId { get; set; } + + /// + /// The team member profile id to apply to this team member. + /// + public long? TeamMemberProfileId { get; set; } + + /// + /// Indicates if the team member access to pay with team wallet when charging. + /// + public bool? CanConfigureChargePoints { get; set; } = false; + /// /// Gives the team member access to pay with team wallet when charging. /// @@ -46,6 +64,11 @@ public class PatchTeamMember public TeamWalletChargePaymentType? TeamWalletChargePaymentType { get; set; } + /// + /// List of country ids for which the team member can pay for charges. + /// + public List? CanPayForChargesCountryIds { get; set; } = new List(); + /// /// A note for the team member. /// @@ -63,5 +86,5 @@ public class PatchTeamMember /// public override string ToString() - => $"{nameof(ChargePointIds)}.Count: {ChargePointIds?.Count ?? 0}, {nameof(Role)}: ({Role}), {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(TeamWalletChargePaymentType)}: ({TeamWalletChargePaymentType}), {nameof(Note)}: {Note}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; + => $"{nameof(ChargePointIds)}.Count: {ChargePointIds?.Count ?? 0}, {nameof(Role)}: ({Role}), {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CostGroupId)}: {CostGroupId}, {nameof(TeamMemberProfileId)}: {TeamMemberProfileId}, {nameof(CanConfigureChargePoints)}: {CanConfigureChargePoints}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(TeamWalletChargePaymentType)}: ({TeamWalletChargePaymentType}), {nameof(CanPayForChargesCountryIds)}.Count: {CanPayForChargesCountryIds?.Count ?? 0}, {nameof(Note)}: {Note}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/RequestParameters/AcceptTeamMemberJoinRequestParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/RequestParameters/AcceptTeamMemberJoinRequestParameters.verified.cs new file mode 100644 index 000000000..ee07915a5 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/RequestParameters/AcceptTeamMemberJoinRequestParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.TeamMembers; + +/// +/// Parameters for operation request. +/// Description: Approve a team member who requested to join a team. +/// Operation: AcceptTeamMemberJoinRequest. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class AcceptTeamMemberJoinRequestParameters +{ + [Required] + public long Id { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/RequestParameters/GetTeamMembersParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/RequestParameters/GetTeamMembersParameters.verified.cs index 2ff54961c..710b81f96 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/RequestParameters/GetTeamMembersParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/RequestParameters/GetTeamMembersParameters.verified.cs @@ -30,7 +30,7 @@ public class GetTeamMembersParameters public TeamMemberRole? Role { get; set; } - public TeamMemberState? State { get; set; } + public TeamMemberState3? State { get; set; } [Range(0, 2147483647)] public long? UserId { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/TeamMemberDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/TeamMember.verified.cs similarity index 70% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/TeamMemberDto.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/TeamMember.verified.cs index 08ba8154a..a318bebe1 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/TeamMemberDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/TeamMembers/TeamMember.verified.cs @@ -7,16 +7,16 @@ namespace Monta.ApiClient.Generated.Contracts.TeamMembers; /// -/// TeamMemberDto. +/// TeamMember. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public class TeamMemberDto +public class TeamMember { /// /// Id of the team member. /// [Required] - public string Id { get; set; } + public long Id { get; set; } /// /// Team id of team member. @@ -28,6 +28,9 @@ public class TeamMemberDto /// public string? DisplayName { get; set; } + /// + /// Operator of this team member. + /// public Operator? Operator { get; set; } /// @@ -40,14 +43,23 @@ public class TeamMemberDto /// public long? UserId { get; set; } + /// + /// Role of the this member within the team. + /// [Required] public TeamMemberRole Role { get; set; } + /// + /// Indicates if the user has access to all charge points or only to selected charge points. + /// [Required] - public TeamMemberAccess Access { get; set; } + public TeamMemberAccess1 Access { get; set; } + /// + /// State of the invitation. + /// [Required] - public TeamMemberState State { get; set; } + public TeamMemberState1 State { get; set; } /// /// Note for team member. @@ -95,6 +107,21 @@ public class TeamMemberDto /// public long? PriceGroupId { get; set; } + /// + /// The cost group for this team member. + /// + public long? CostGroupId { get; set; } + + /// + /// The team member profile id to apply to this team member. + /// + public long? TeamMemberProfileId { get; set; } + + /// + /// Indicates if the team member access to pay with team wallet when charging. + /// + public bool CanConfigureChargePoints { get; set; } = false; + /// /// Indicates if the team member access to pay with team wallet when charging. /// @@ -115,6 +142,12 @@ public class TeamMemberDto /// public bool CanManageTeamMembers { get; set; } = false; + /// + /// List of country ids for which the team member can pay for charges. + /// + [Required] + public List CanPayForChargesCountryIds { get; set; } + /// /// Who can pay the charging with Wallet?. /// @@ -133,5 +166,5 @@ public class TeamMemberDto /// public override string ToString() - => $"{nameof(Id)}: {Id}, {nameof(TeamId)}: {TeamId}, {nameof(DisplayName)}: {DisplayName}, {nameof(Operator)}: ({Operator}), {nameof(PartnerExternalTeamId)}: {PartnerExternalTeamId}, {nameof(UserId)}: {UserId}, {nameof(Role)}: ({Role}), {nameof(Access)}: ({Access}), {nameof(State)}: ({State}), {nameof(Note)}: {Note}, {nameof(InvitedAt)}: ({InvitedAt}), {nameof(AcceptedAt)}: ({AcceptedAt}), {nameof(RejectedAt)}: ({RejectedAt}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt}), {nameof(ChargePointIds)}.Count: {ChargePointIds?.Count ?? 0}, {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(TeamWalletChargePaymentType)}: {TeamWalletChargePaymentType}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; + => $"{nameof(Id)}: {Id}, {nameof(TeamId)}: {TeamId}, {nameof(DisplayName)}: {DisplayName}, {nameof(Operator)}: ({Operator}), {nameof(PartnerExternalTeamId)}: {PartnerExternalTeamId}, {nameof(UserId)}: {UserId}, {nameof(Role)}: ({Role}), {nameof(Access)}: ({Access}), {nameof(State)}: ({State}), {nameof(Note)}: {Note}, {nameof(InvitedAt)}: ({InvitedAt}), {nameof(AcceptedAt)}: ({AcceptedAt}), {nameof(RejectedAt)}: ({RejectedAt}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt}), {nameof(ChargePointIds)}.Count: {ChargePointIds?.Count ?? 0}, {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CostGroupId)}: {CostGroupId}, {nameof(TeamMemberProfileId)}: {TeamMemberProfileId}, {nameof(CanConfigureChargePoints)}: {CanConfigureChargePoints}, {nameof(CanPayWithTeamWallet)}: {CanPayWithTeamWallet}, {nameof(CanManageTeamWallet)}: {CanManageTeamWallet}, {nameof(CanRequestSponsoring)}: {CanRequestSponsoring}, {nameof(CanManageTeamMembers)}: {CanManageTeamMembers}, {nameof(CanPayForChargesCountryIds)}.Count: {CanPayForChargesCountryIds?.Count ?? 0}, {nameof(TeamWalletChargePaymentType)}: {TeamWalletChargePaymentType}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/CreateTeamDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/CreateTeamDto.verified.cs index 67a9104e3..2d957cce9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/CreateTeamDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/CreateTeamDto.verified.cs @@ -18,7 +18,7 @@ public class CreateTeamDto public long? UserId { get; set; } /// - /// email of the user that owns the team, useful when the userId is not known. + /// Email of the user that owns the team, useful when the userId is not known. /// /// /// Email validation being enforced. @@ -26,6 +26,12 @@ public class CreateTeamDto [EmailAddress] public string? UserEmail { get; set; } + /// + /// Id of the operator this team should be assigned to<br />*Note*: if not provided the team will be assigned to the default operator for the given consumer, if the default operator cannot be assigned the request will be rejected. + /// + [Range(0, int.MaxValue)] + public long? OperatorId { get; set; } + /// /// Name of the team. /// @@ -43,9 +49,15 @@ public class CreateTeamDto [EmailAddress] public string ContactEmail { get; set; } + /// + /// type of the team. + /// [Required] public TeamTypeCreatable Type { get; set; } + /// + /// Address of the team, Note: be sure to add always a valid address. + /// [Required] public CreatedOrUpdateAddress Address { get; set; } @@ -80,5 +92,5 @@ public class CreateTeamDto /// public override string ToString() - => $"{nameof(UserId)}: {UserId}, {nameof(UserEmail)}: {UserEmail}, {nameof(Name)}: {Name}, {nameof(ContactEmail)}: {ContactEmail}, {nameof(Type)}: ({Type}), {nameof(Address)}: ({Address}), {nameof(CompanyName)}: {CompanyName}, {nameof(VatNumber)}: {VatNumber}, {nameof(FinanceEmail)}: {FinanceEmail}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; + => $"{nameof(UserId)}: {UserId}, {nameof(UserEmail)}: {UserEmail}, {nameof(OperatorId)}: {OperatorId}, {nameof(Name)}: {Name}, {nameof(ContactEmail)}: {ContactEmail}, {nameof(Type)}: ({Type}), {nameof(Address)}: ({Address}), {nameof(CompanyName)}: {CompanyName}, {nameof(VatNumber)}: {VatNumber}, {nameof(FinanceEmail)}: {FinanceEmail}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/Currency7.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/Currency7.verified.cs new file mode 100644 index 000000000..316cd3b77 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/Currency7.verified.cs @@ -0,0 +1,35 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Teams; + +/// +/// Currency7. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Currency7 +{ + /// + /// Currency identifier, e.g. dkk. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Readable name of currency. + /// + [Required] + public string Name { get; set; } + + /// + /// Number of decimals for this currency. + /// + public int Decimals { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/PatchTeam.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/PatchTeam.verified.cs index fc5fa7b82..1d3dedd11 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/PatchTeam.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/PatchTeam.verified.cs @@ -40,6 +40,9 @@ public class PatchTeam [EmailAddress] public string? ContactEmail { get; set; } + /// + /// Address of the team. + /// public CreatedOrUpdateAddress? Address { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/FreezeTeamParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/FreezeTeamParameters.verified.cs new file mode 100644 index 000000000..51dd37c38 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/FreezeTeamParameters.verified.cs @@ -0,0 +1,26 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Teams; + +/// +/// Parameters for operation request. +/// Description: Freeze a team. +/// Operation: FreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class FreezeTeamParameters +{ + [Required] + public long Id { get; set; } + + [Required] + public UpdateTeamStateDto Request { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(Request)}: ({Request})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/GetTeamsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/GetTeamsParameters.verified.cs index cefeef68d..227fa36fb 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/GetTeamsParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/GetTeamsParameters.verified.cs @@ -14,16 +14,6 @@ namespace Monta.ApiClient.Generated.Contracts.Teams; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class GetTeamsParameters { - /// - /// Filter teams by partnerExternalId, to filter only resources without `partnerExternalId` *use* `partnerExternalId=""`. - /// - public string PartnerExternalId { get; set; } - - /// - /// Filter to include delete teams in the response. - /// - public bool IncludeDeleted { get; set; } = false; - /// /// page number to retrieve (starts with 0). /// @@ -36,5 +26,5 @@ public class GetTeamsParameters /// public override string ToString() - => $"{nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(IncludeDeleted)}: {IncludeDeleted}, {nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}"; + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/UnfreezeTeamParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/UnfreezeTeamParameters.verified.cs new file mode 100644 index 000000000..ad8c8b79f --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/RequestParameters/UnfreezeTeamParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Teams; + +/// +/// Parameters for operation request. +/// Description: Unfreeze a team. +/// Operation: UnfreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UnfreezeTeamParameters +{ + [Required] + public long Id { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/Team.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/Team.verified.cs index 3b2ea93ae..82bc9e4ea 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/Team.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/Team.verified.cs @@ -54,13 +54,22 @@ public class Team /// public string? VatNumber { get; set; } + /// + /// The operator to this team is associated. + /// public Operator? Operator { get; set; } + /// + /// The address where the team is located. + /// [Required] public TeamDtoTeamAddressDto Address { get; set; } + /// + /// The currency assigned for this team. + /// [Required] - public Currency Currency { get; set; } + public Currency7 Currency { get; set; } /// /// Type of the team. @@ -68,11 +77,31 @@ public class Team [Required] public string Type { get; set; } + /// + /// Category of the team. + /// + public TeamDtoTeamCategoryDto? Category { get; set; } + /// /// Id of the user that owns this team. /// public long UserId { get; set; } + /// + /// Whether the team is frozen or not. + /// + public bool IsFrozen { get; set; } + + /// + /// Team freezing reason. + /// + public string? FrozenReason { get; set; } + + /// + /// Frozen date of this team. + /// + public DateTimeOffset? FrozenAt { get; set; } + /// /// Blocked date of this team. /// @@ -97,5 +126,5 @@ public class Team /// public override string ToString() - => $"{nameof(Id)}: {Id}, {nameof(Name)}: {Name}, {nameof(ExternalId)}: {ExternalId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}, {nameof(JoinCode)}: {JoinCode}, {nameof(CompanyName)}: {CompanyName}, {nameof(VatNumber)}: {VatNumber}, {nameof(Operator)}: ({Operator}), {nameof(Address)}: ({Address}), {nameof(Currency)}: ({Currency}), {nameof(Type)}: {Type}, {nameof(UserId)}: {UserId}, {nameof(BlockedAt)}: ({BlockedAt}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt})"; + => $"{nameof(Id)}: {Id}, {nameof(Name)}: {Name}, {nameof(ExternalId)}: {ExternalId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}, {nameof(JoinCode)}: {JoinCode}, {nameof(CompanyName)}: {CompanyName}, {nameof(VatNumber)}: {VatNumber}, {nameof(Operator)}: ({Operator}), {nameof(Address)}: ({Address}), {nameof(Currency)}: ({Currency}), {nameof(Type)}: {Type}, {nameof(Category)}: ({Category}), {nameof(UserId)}: {UserId}, {nameof(IsFrozen)}: {IsFrozen}, {nameof(FrozenReason)}: {FrozenReason}, {nameof(FrozenAt)}: ({FrozenAt}), {nameof(BlockedAt)}: ({BlockedAt}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/TeamDtoTeamCategoryDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/TeamDtoTeamCategoryDto.verified.cs new file mode 100644 index 000000000..4e46c5875 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/TeamDtoTeamCategoryDto.verified.cs @@ -0,0 +1,30 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Teams; + +/// +/// TeamDtoTeamCategoryDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class TeamDtoTeamCategoryDto +{ + /// + /// Category Identifier. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Category name. + /// + [Required] + public string Name { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/UpdateTeamStateDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/UpdateTeamStateDto.verified.cs new file mode 100644 index 000000000..5ba014703 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Teams/UpdateTeamStateDto.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Teams; + +/// +/// UpdateTeamStateDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UpdateTeamStateDto +{ + /// + /// Team freezing reason. + /// + public string? Reason { get; set; } + + /// + public override string ToString() + => $"{nameof(Reason)}: {Reason}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/MontaPageUserDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/MontaPageUserDto.verified.cs new file mode 100644 index 000000000..bbf5ce7b1 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/MontaPageUserDto.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Users; + +/// +/// MontaPageUserDto. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class MontaPageUserDto +{ + [Required] + public List Data { get; set; } + + [Required] + public MontaPageMeta Meta { get; set; } + + /// + public override string ToString() + => $"{nameof(Data)}.Count: {Data?.Count ?? 0}, {nameof(Meta)}: ({Meta})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/RequestParameters/GetUserParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/RequestParameters/GetUserParameters.verified.cs new file mode 100644 index 000000000..fe565c494 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/RequestParameters/GetUserParameters.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Users; + +/// +/// Parameters for operation request. +/// Description: Retrieve a user. +/// Operation: GetUser. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetUserParameters +{ + [Required] + public long UserId { get; set; } + + /// + public override string ToString() + => $"{nameof(UserId)}: {UserId}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/RequestParameters/GetUsersParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/RequestParameters/GetUsersParameters.verified.cs new file mode 100644 index 000000000..f62769fa3 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/RequestParameters/GetUsersParameters.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Users; + +/// +/// Parameters for operation request. +/// Description: Retrieve users. +/// Operation: GetUsers. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetUsersParameters +{ + /// + /// page number to retrieve (starts with 0). + /// + public int Page { get; set; } = 0; + + /// + /// number of items per page (between 1 and 100, default 10). + /// + public int PerPage { get; set; } = 10; + + /// + /// filter user by email. + /// + /// + /// Email validation being enforced. + /// + [EmailAddress] + public string Email { get; set; } + + /// + /// filter user by phone. + /// + public string Phone { get; set; } + + /// + /// Set to 'true' to include deleted users, 'false' otherwise. + /// + public bool IncludeDeleted { get; set; } = false; + + /// + public override string ToString() + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(Email)}: {Email}, {nameof(Phone)}: {Phone}, {nameof(IncludeDeleted)}: {IncludeDeleted}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/User.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/User.verified.cs new file mode 100644 index 000000000..0d295f748 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Users/User.verified.cs @@ -0,0 +1,79 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.Users; + +/// +/// User. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class User +{ + /// + /// Id of the user. + /// + [Required] + public long Id { get; set; } + + /// + /// First name of the user. + /// + public string? FirstName { get; set; } + + /// + /// Last name of the user. + /// + public string? LastName { get; set; } + + /// + /// Email of the user. + /// + public string? Email { get; set; } + + /// + /// Phone number of the user. + /// + public string? Phone { get; set; } + + /// + /// URL of the profile image. + /// + public string? ProfileImageUrl { get; set; } + + /// + /// Address of the user. + /// + public Address? Address { get; set; } + + /// + /// Preferred language of the user. + /// + public string? Language { get; set; } + + /// + /// Timestamp when the user read the terms. + /// + public DateTimeOffset? TermsReadAt { get; set; } + + /// + /// Timestamp when the user was created. + /// + public DateTimeOffset? CreatedAt { get; set; } + + /// + /// Timestamp when the user was last updated. + /// + public DateTimeOffset? UpdatedAt { get; set; } + + /// + /// Timestamp when the user was deleted. + /// + public DateTimeOffset? DeletedAt { get; set; } + + /// + public override string ToString() + => $"{nameof(Id)}: {Id}, {nameof(FirstName)}: {FirstName}, {nameof(LastName)}: {LastName}, {nameof(Email)}: {Email}, {nameof(Phone)}: {Phone}, {nameof(ProfileImageUrl)}: {ProfileImageUrl}, {nameof(Address)}: ({Address}), {nameof(Language)}: {Language}, {nameof(TermsReadAt)}: ({TermsReadAt}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt})"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/Currency13.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/Currency13.verified.cs new file mode 100644 index 000000000..699fb11f9 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/Currency13.verified.cs @@ -0,0 +1,35 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.WalletTransactions; + +/// +/// Currency13. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Currency13 +{ + /// + /// Currency identifier, e.g. dkk. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Readable name of currency. + /// + [Required] + public string Name { get; set; } + + /// + /// Number of decimals for this currency. + /// + public int Decimals { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/Currency14.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/Currency14.verified.cs new file mode 100644 index 000000000..8d129a10d --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/Currency14.verified.cs @@ -0,0 +1,35 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts.WalletTransactions; + +/// +/// Currency14. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Currency14 +{ + /// + /// Currency identifier, e.g. dkk. + /// + [Required] + public string Identifier { get; set; } + + /// + /// Readable name of currency. + /// + [Required] + public string Name { get; set; } + + /// + /// Number of decimals for this currency. + /// + public int Decimals { get; set; } + + /// + public override string ToString() + => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/OperatorAdjustmentTransaction.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/OperatorAdjustmentTransaction.verified.cs index 090c27be0..e6c1e2140 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/OperatorAdjustmentTransaction.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/OperatorAdjustmentTransaction.verified.cs @@ -39,17 +39,7 @@ public class OperatorAdjustmentTransaction /// public double Amount { get; set; } - /// - /// External Id of this entity, managed by you. - /// - public string? PartnerExternalId { get; set; } - - /// - /// Custom JSON payload for this entity, managed by you. - /// - public List? PartnerCustomPayload { get; set; } = new List(); - /// public override string ToString() - => $"{nameof(FromWalletId)}: {FromWalletId}, {nameof(ToWalletId)}: {ToWalletId}, {nameof(Note)}: {Note}, {nameof(CurrencyId)}: {CurrencyId}, {nameof(Amount)}: {Amount}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}"; + => $"{nameof(FromWalletId)}: {FromWalletId}, {nameof(ToWalletId)}: {ToWalletId}, {nameof(Note)}: {Note}, {nameof(CurrencyId)}: {CurrencyId}, {nameof(Amount)}: {Amount}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/PatchTransactionParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/GetWalletTransactions1Parameters.verified.cs similarity index 65% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/PatchTransactionParameters.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/GetWalletTransactions1Parameters.verified.cs index a589b7716..9b48de032 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/PatchTransactionParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/GetWalletTransactions1Parameters.verified.cs @@ -8,19 +8,19 @@ namespace Monta.ApiClient.Generated.Contracts.WalletTransactions; /// /// Parameters for operation request. -/// Description: Patch an existing transaction. -/// Operation: PatchTransaction. +/// Description: Retrieves wallet transactions for an invoice. +/// Operation: GetWalletTransactions1. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public class PatchTransactionParameters +public class GetWalletTransactions1Parameters { [Required] - public long TransactionId { get; set; } + public long InvoiceId { get; set; } [Required] - public PatchWalletTransaction Request { get; set; } + public Pageable Pageable { get; set; } /// public override string ToString() - => $"{nameof(TransactionId)}: {TransactionId}, {nameof(Request)}: ({Request})"; + => $"{nameof(InvoiceId)}: {InvoiceId}, {nameof(Pageable)}: ({Pageable})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/GetWalletTransactionsParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/GetWalletTransactionsParameters.verified.cs index 68d3bf5f0..135e3c1ed 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/GetWalletTransactionsParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/RequestParameters/GetWalletTransactionsParameters.verified.cs @@ -24,6 +24,8 @@ public class GetWalletTransactionsParameters /// public int PerPage { get; set; } = 10; + public int? OperatorId { get; set; } + public int? TeamId { get; set; } [RegularExpression("^(\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2})Z$")] @@ -44,5 +46,5 @@ public class GetWalletTransactionsParameters /// public override string ToString() - => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(TeamId)}: {TeamId}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(ReferenceId)}: {ReferenceId}, {nameof(ReferenceType)}: ({ReferenceType}), {nameof(State)}: ({State}), {nameof(Group)}: ({Group}), {nameof(PartnerExternalId)}: {PartnerExternalId}"; + => $"{nameof(Page)}: {Page}, {nameof(PerPage)}: {PerPage}, {nameof(OperatorId)}: {OperatorId}, {nameof(TeamId)}: {TeamId}, {nameof(FromDate)}: ({FromDate}), {nameof(ToDate)}: ({ToDate}), {nameof(ReferenceId)}: {ReferenceId}, {nameof(ReferenceType)}: ({ReferenceType}), {nameof(State)}: ({State}), {nameof(Group)}: ({Group}), {nameof(PartnerExternalId)}: {PartnerExternalId}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/WalletTransaction.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/WalletTransaction.verified.cs index e0cea0ced..cb872eb68 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/WalletTransaction.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/WalletTransactions/WalletTransaction.verified.cs @@ -32,14 +32,20 @@ public class WalletTransaction /// public double FromVatAmount { get; set; } + /// + /// Currency for `fromAmount`. + /// [Required] - public Currency FromCurrency { get; set; } + public Currency13 FromCurrency { get; set; } /// /// Type of sender: operator, team. /// public string? FromType { get; set; } + /// + /// Type of sender: operator, team. + /// public TeamOrOperator? From { get; set; } /// @@ -62,14 +68,20 @@ public class WalletTransaction /// public double ToVatAmount { get; set; } + /// + /// Currency used for `toAmount`. + /// [Required] - public Currency ToCurrency { get; set; } + public Currency14 ToCurrency { get; set; } /// /// Type of receiver: operator, team. /// public string? ToType { get; set; } + /// + /// Type of sender: operator, team. + /// public TeamOrOperator? To { get; set; } /// @@ -93,13 +105,24 @@ public class WalletTransaction /// public DateTimeOffset? UpdatedAt { get; set; } + /// + /// Completion date of transaction. + /// + public DateTimeOffset? CompletedAt { get; set; } + /// /// Reference id of this transaction. e.g the charge id. /// public string? ReferenceId { get; set; } + /// + /// Reference type of this transaction. + /// public WalletTransactionReferenceType? ReferenceType { get; set; } + /// + /// Transaction group of this transaction. + /// [Required] public WalletTransactionGroup Group { get; set; } @@ -116,6 +139,9 @@ public class WalletTransaction /// public double VatPercentage { get; set; } + /// + /// Transaction state of this transaction. + /// [Required] public WalletTransactionState State { get; set; } @@ -125,18 +151,11 @@ public class WalletTransaction public string? Note { get; set; } /// - /// External Id of this entity, managed by you. + /// Additional information for this transaction. /// - public string? PartnerExternalId { get; set; } - - /// - /// Custom JSON payload for this entity, managed by you. - /// - public List? PartnerCustomPayload { get; set; } = new List(); - public MetadataDto? Metadata { get; set; } /// public override string ToString() - => $"{nameof(Id)}: {Id}, {nameof(FromAmount)}: {FromAmount}, {nameof(FromSubAmount)}: {FromSubAmount}, {nameof(FromVatAmount)}: {FromVatAmount}, {nameof(FromCurrency)}: ({FromCurrency}), {nameof(FromType)}: {FromType}, {nameof(From)}: ({From}), {nameof(FromWalletId)}: {FromWalletId}, {nameof(ToAmount)}: {ToAmount}, {nameof(ToSubAmount)}: {ToSubAmount}, {nameof(ToVatAmount)}: {ToVatAmount}, {nameof(ToCurrency)}: ({ToCurrency}), {nameof(ToType)}: {ToType}, {nameof(To)}: ({To}), {nameof(ToWalletId)}: {ToWalletId}, {nameof(ExchangeRate)}: {ExchangeRate}, {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(ReferenceId)}: {ReferenceId}, {nameof(ReferenceType)}: ({ReferenceType}), {nameof(Group)}: ({Group}), {nameof(Kind)}: {Kind}, {nameof(VatPercentage)}: {VatPercentage}, {nameof(State)}: ({State}), {nameof(Note)}: {Note}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}, {nameof(Metadata)}: ({Metadata})"; + => $"{nameof(Id)}: {Id}, {nameof(FromAmount)}: {FromAmount}, {nameof(FromSubAmount)}: {FromSubAmount}, {nameof(FromVatAmount)}: {FromVatAmount}, {nameof(FromCurrency)}: ({FromCurrency}), {nameof(FromType)}: {FromType}, {nameof(From)}: ({From}), {nameof(FromWalletId)}: {FromWalletId}, {nameof(ToAmount)}: {ToAmount}, {nameof(ToSubAmount)}: {ToSubAmount}, {nameof(ToVatAmount)}: {ToVatAmount}, {nameof(ToCurrency)}: ({ToCurrency}), {nameof(ToType)}: {ToType}, {nameof(To)}: ({To}), {nameof(ToWalletId)}: {ToWalletId}, {nameof(ExchangeRate)}: {ExchangeRate}, {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(CompletedAt)}: ({CompletedAt}), {nameof(ReferenceId)}: {ReferenceId}, {nameof(ReferenceType)}: ({ReferenceType}), {nameof(Group)}: ({Group}), {nameof(Kind)}: {Kind}, {nameof(VatPercentage)}: {VatPercentage}, {nameof(State)}: ({State}), {nameof(Note)}: {Note}, {nameof(Metadata)}: ({Metadata})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Wallets/Wallet.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Wallets/Wallet.verified.cs index 368dce5b9..e6868d592 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Wallets/Wallet.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Wallets/Wallet.verified.cs @@ -38,6 +38,9 @@ public class Wallet /// public long CountryId { get; set; } + /// + /// Balance of this wallet, if available (not in list endpoints). + /// public WalletDtoBalanceDto? Balance { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/RequestParameters/GetWebhookEntriesParameters.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/RequestParameters/GetWebhookEntriesParameters.verified.cs index 73b1aff23..eb340e68b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/RequestParameters/GetWebhookEntriesParameters.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/RequestParameters/GetWebhookEntriesParameters.verified.cs @@ -24,10 +24,7 @@ public class GetWebhookEntriesParameters /// public int PerPage { get; set; } = 10; - /// - /// The status from which webhook entries will be filtered by. - /// - public long Status { get; set; } + public string? Status { get; set; } /// public override string ToString() diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookConfig.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookConfig.verified.cs index 6de7c3b46..74848fd22 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookConfig.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookConfig.verified.cs @@ -17,7 +17,7 @@ public class WebhookConfig /// [Required] [StringLength(191)] - [RegularExpression("https://.*")] + [RegularExpression("https://(?!(.*monta\\.com?)).*")] public string WebhookUrl { get; set; } /// @@ -29,9 +29,10 @@ public class WebhookConfig public string WebhookSecret { get; set; } /// - /// A list of event type to subscribe to. Use ["*"] to subscribe to all. + /// A list of event types to subscribe to. /// - public List EventTypes { get; set; } = new List(); + [Required] + public List EventTypes { get; set; } /// public override string ToString() diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookEntry.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookEntry.verified.cs index ac4108ece..6d782b3f6 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookEntry.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookEntry.verified.cs @@ -27,15 +27,28 @@ public class WebhookEntry /// public long OperatorId { get; set; } + /// + /// Type of event this entry belongs to. + /// Note: This is not the type of the entity (payload.EntityType), but the type of the event that you can subscribe to. + /// [Required] public WebhookEntryEventType EventType { get; set; } + /// + /// payload of this entry. + /// [Required] public WebhookEntryPayload Payload { get; set; } + /// + /// Status of the entry. + /// [Required] public WebhookEntryStatus Status { get; set; } + /// + /// Contains the error message if the delivery failed. + /// public WebhookEntryErrorPayload? Error { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookEntryPayload.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookEntryPayload.verified.cs index 04e6afd01..5e72de16d 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookEntryPayload.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Webhooks/WebhookEntryPayload.verified.cs @@ -12,6 +12,9 @@ namespace Monta.ApiClient.Generated.Contracts.Webhooks; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class WebhookEntryPayload { + /// + /// Type of the entity. + /// [Required] public WebhookEntryPayloadEntityType EntityType { get; set; } @@ -21,9 +24,17 @@ public class WebhookEntryPayload [Required] public string EntityId { get; set; } + /// + /// Type of the event. + /// [Required] public KafkaEventType EventType { get; set; } + /// + /// The timestamp indicating when the event was generated. + /// + public DateTimeOffset? EventTime { get; set; } + /// /// payload of this entity, e.g. a full Charge object. /// @@ -31,5 +42,5 @@ public class WebhookEntryPayload /// public override string ToString() - => $"{nameof(EntityType)}: ({EntityType}), {nameof(EntityId)}: {EntityId}, {nameof(EventType)}: ({EventType}), {nameof(Payload)}.Count: {Payload?.Count ?? 0}"; + => $"{nameof(EntityType)}: ({EntityType}), {nameof(EntityId)}: {EntityId}, {nameof(EventType)}: ({EventType}), {nameof(EventTime)}: ({EventTime}), {nameof(Payload)}.Count: {Payload?.Count ?? 0}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/ComponentTypeDto.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/ComponentTypeDto.verified.cs index b6cce361a..44e3002f8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/ComponentTypeDto.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/ComponentTypeDto.verified.cs @@ -49,6 +49,9 @@ public enum ComponentTypeDto [EnumMember(Value = "adjustment")] Adjustment, + [EnumMember(Value = "bilateral-agreement")] + BilateralAgreement, + [EnumMember(Value = "other")] Other, } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/ElectricCurrentType.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/ElectricCurrentType.verified.cs index 4e1ed738e..99d3b1389 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/ElectricCurrentType.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/ElectricCurrentType.verified.cs @@ -18,4 +18,7 @@ public enum ElectricCurrentType [EnumMember(Value = "dc")] Dc, + + [EnumMember(Value = "other")] + Other, } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/SubscriptionCustomerType.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/SubscriptionCustomerType.verified.cs index 6dd6f009f..e46b747b3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/SubscriptionCustomerType.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/SubscriptionCustomerType.verified.cs @@ -10,18 +10,10 @@ namespace Monta.ApiClient.Generated.Contracts; /// Enumeration: SubscriptionCustomerType. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -[JsonConverter(typeof(JsonStringEnumConverter))] public enum SubscriptionCustomerType { - [EnumMember(Value = "team")] - Team, - - [EnumMember(Value = "charge-point")] - ChargePoint, - - [EnumMember(Value = "operator")] - Operator, - - [EnumMember(Value = "other")] - Other, + TEAM, + CHARGE_POINT, + OPERATOR, + OTHER, } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberAccess.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberAccess.verified.cs index 2d51595c1..ce2cdb0f9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberAccess.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberAccess.verified.cs @@ -18,7 +18,4 @@ public enum TeamMemberAccess [EnumMember(Value = "selected")] Selected, - - [EnumMember(Value = "other")] - Other, } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberAccess1.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberAccess1.verified.cs new file mode 100644 index 000000000..f31f048d1 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberAccess1.verified.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts; + +/// +/// Enumeration: TeamMemberAccess1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +[JsonConverter(typeof(JsonStringEnumConverter))] +public enum TeamMemberAccess1 +{ + [EnumMember(Value = "all")] + All, + + [EnumMember(Value = "selected")] + Selected, + + [EnumMember(Value = "other")] + Other, +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState.verified.cs index 8bddc6fad..20ea1b813 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState.verified.cs @@ -19,18 +19,15 @@ public enum TeamMemberState [EnumMember(Value = "invited")] Invited, - [EnumMember(Value = "rejected")] - Rejected, - [EnumMember(Value = "accepted")] Accepted, + [EnumMember(Value = "rejected_at")] + RejectedAt, + [EnumMember(Value = "blocked")] Blocked, [EnumMember(Value = "expired")] Expired, - - [EnumMember(Value = "other")] - Other, } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState1.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState1.verified.cs new file mode 100644 index 000000000..b2cb51ba9 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState1.verified.cs @@ -0,0 +1,36 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts; + +/// +/// Enumeration: TeamMemberState1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +[JsonConverter(typeof(JsonStringEnumConverter))] +public enum TeamMemberState1 +{ + [EnumMember(Value = "requested")] + Requested, + + [EnumMember(Value = "invited")] + Invited, + + [EnumMember(Value = "rejected")] + Rejected, + + [EnumMember(Value = "accepted")] + Accepted, + + [EnumMember(Value = "blocked")] + Blocked, + + [EnumMember(Value = "expired")] + Expired, + + [EnumMember(Value = "other")] + Other, +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState3.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState3.verified.cs new file mode 100644 index 000000000..6052737f9 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/TeamMemberState3.verified.cs @@ -0,0 +1,36 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts; + +/// +/// Enumeration: TeamMemberState3. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +[JsonConverter(typeof(JsonStringEnumConverter))] +public enum TeamMemberState3 +{ + [EnumMember(Value = "requested")] + Requested, + + [EnumMember(Value = "invited")] + Invited, + + [EnumMember(Value = "rejected")] + Rejected, + + [EnumMember(Value = "accepted")] + Accepted, + + [EnumMember(Value = "blocked")] + Blocked, + + [EnumMember(Value = "expired")] + Expired, + + [EnumMember(Value = "other")] + Other, +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/WebhookEntryEventType.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/WebhookEntryEventType.verified.cs index ab40da618..48a4ab49b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/WebhookEntryEventType.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/WebhookEntryEventType.verified.cs @@ -13,9 +13,6 @@ namespace Monta.ApiClient.Generated.Contracts; [JsonConverter(typeof(JsonStringEnumConverter))] public enum WebhookEntryEventType { - [EnumMember(Value = "*")] - None, - [EnumMember(Value = "charges")] Charges, @@ -25,6 +22,9 @@ public enum WebhookEntryEventType [EnumMember(Value = "sites")] Sites, + [EnumMember(Value = "users")] + Users, + [EnumMember(Value = "team-members")] TeamMembers, @@ -45,4 +45,10 @@ public enum WebhookEntryEventType [EnumMember(Value = "plans")] Plans, + + [EnumMember(Value = "charge-auth-tokens")] + ChargeAuthTokens, + + [EnumMember(Value = "reports")] + Reports, } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/WebhookEntryPayloadEntityType.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/WebhookEntryPayloadEntityType.verified.cs index ba745105e..715bf4fc9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/WebhookEntryPayloadEntityType.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_EnumerationTypes/WebhookEntryPayloadEntityType.verified.cs @@ -22,6 +22,9 @@ public enum WebhookEntryPayloadEntityType [EnumMember(Value = "site")] Site, + [EnumMember(Value = "user")] + User, + [EnumMember(Value = "team")] Team, @@ -42,4 +45,10 @@ public enum WebhookEntryPayloadEntityType [EnumMember(Value = "plan")] Plan, + + [EnumMember(Value = "charge-auth-token")] + ChargeAuthToken, + + [EnumMember(Value = "report")] + Report, } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/AdditionalPricing.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/AdditionalPricing.verified.cs index bac4fa8c7..9221f13a7 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/AdditionalPricing.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/AdditionalPricing.verified.cs @@ -12,13 +12,24 @@ namespace Monta.ApiClient.Generated.Contracts; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class AdditionalPricing { + /// + /// Type of the additional pricing. `absolute` means the value is a price. + /// [Required] public AdditionalPricingType Type { get; set; } + /// + /// The value of this additional pricing. Both `absolute` and `percentage` values here are represented as a money object. + /// [Required] public Money Value { get; set; } + /// + /// A title for this additional pricing. + /// + public string? Title { get; set; } + /// public override string ToString() - => $"{nameof(Type)}: ({Type}), {nameof(Value)}: ({Value})"; + => $"{nameof(Type)}: ({Type}), {nameof(Value)}: ({Value}), {nameof(Title)}: {Title}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/ChargePoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/ChargePoint.verified.cs index 042050c0a..4b6b1f753 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/ChargePoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/ChargePoint.verified.cs @@ -37,6 +37,9 @@ public class ChargePoint /// public long? SiteId { get; set; } + /// + /// Operator of this charge point. + /// public Operator? Operator { get; set; } /// @@ -97,8 +100,14 @@ public class ChargePoint /// public string? OperatorNote { get; set; } + /// + /// State of the charge point. + /// public ChargePointState? State { get; set; } + /// + /// Location information for this charge point. + /// [Required] public Location Location { get; set; } @@ -108,6 +117,9 @@ public class ChargePoint [Required] public List Connectors { get; set; } + /// + /// Deeplinks to open charge screen in Monta app or web. + /// [Required] public ChargePointDeeplinks Deeplinks { get; set; } @@ -141,6 +153,9 @@ public class ChargePoint /// public string? FirmwareVersion { get; set; } + /// + /// Indicates what kind of integration this charge point is using (e.g oicp, ocpi, Note: null meaning not integrated). + /// public ChargePointIntegrationType? IntegrationType { get; set; } /// @@ -184,7 +199,27 @@ public class ChargePoint /// public int? ReservationTime { get; set; } + /// + /// SIM card data for the given charge point. + /// + public SimCard? SimCard { get; set; } + + /// + /// Indicates whether roaming is enabled for this charge point. + /// + public bool Roaming { get; set; } + + /// + /// The last date/time this charge point was reported as connected. + /// + public DateTimeOffset? LastConnectedAt { get; set; } + + /// + /// The date/time this charge point was reported as disconnected. + /// + public DateTimeOffset? DisconnectedAt { get; set; } + /// public override string ToString() - => $"{nameof(Id)}: {Id}, {nameof(TeamId)}: {TeamId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}, {nameof(SiteId)}: {SiteId}, {nameof(Operator)}: ({Operator}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt}), {nameof(ActiveAt)}: ({ActiveAt}), {nameof(SerialNumber)}: {SerialNumber}, {nameof(Name)}: {Name}, {nameof(Visibility)}: {Visibility}, {nameof(MaxKw)}: {MaxKw}, {nameof(Type)}: {Type}, {nameof(Note)}: {Note}, {nameof(OperatorNote)}: {OperatorNote}, {nameof(State)}: ({State}), {nameof(Location)}: ({Location}), {nameof(Connectors)}.Count: {Connectors?.Count ?? 0}, {nameof(Deeplinks)}: ({Deeplinks}), {nameof(LastMeterReadingKwh)}: {LastMeterReadingKwh}, {nameof(CablePluggedIn)}: {CablePluggedIn}, {nameof(ChargePointModelId)}: {ChargePointModelId}, {nameof(BrandName)}: {BrandName}, {nameof(ModelName)}: {ModelName}, {nameof(FirmwareVersion)}: {FirmwareVersion}, {nameof(IntegrationType)}: ({IntegrationType}), {nameof(EvseId)}: {EvseId}, {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CostGroupId)}: {CostGroupId}, {nameof(RoamingPriceGroupId)}: {RoamingPriceGroupId}, {nameof(SponsoredPriceGroupId)}: {SponsoredPriceGroupId}, {nameof(IsActive)}: {IsActive}, {nameof(Reservable)}: {Reservable}, {nameof(ReservationTime)}: {ReservationTime}"; + => $"{nameof(Id)}: {Id}, {nameof(TeamId)}: {TeamId}, {nameof(PartnerExternalId)}: {PartnerExternalId}, {nameof(PartnerCustomPayload)}.Count: {PartnerCustomPayload?.Count ?? 0}, {nameof(SiteId)}: {SiteId}, {nameof(Operator)}: ({Operator}), {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt}), {nameof(DeletedAt)}: ({DeletedAt}), {nameof(ActiveAt)}: ({ActiveAt}), {nameof(SerialNumber)}: {SerialNumber}, {nameof(Name)}: {Name}, {nameof(Visibility)}: {Visibility}, {nameof(MaxKw)}: {MaxKw}, {nameof(Type)}: {Type}, {nameof(Note)}: {Note}, {nameof(OperatorNote)}: {OperatorNote}, {nameof(State)}: ({State}), {nameof(Location)}: ({Location}), {nameof(Connectors)}.Count: {Connectors?.Count ?? 0}, {nameof(Deeplinks)}: ({Deeplinks}), {nameof(LastMeterReadingKwh)}: {LastMeterReadingKwh}, {nameof(CablePluggedIn)}: {CablePluggedIn}, {nameof(ChargePointModelId)}: {ChargePointModelId}, {nameof(BrandName)}: {BrandName}, {nameof(ModelName)}: {ModelName}, {nameof(FirmwareVersion)}: {FirmwareVersion}, {nameof(IntegrationType)}: ({IntegrationType}), {nameof(EvseId)}: {EvseId}, {nameof(PriceGroupId)}: {PriceGroupId}, {nameof(CostGroupId)}: {CostGroupId}, {nameof(RoamingPriceGroupId)}: {RoamingPriceGroupId}, {nameof(SponsoredPriceGroupId)}: {SponsoredPriceGroupId}, {nameof(IsActive)}: {IsActive}, {nameof(Reservable)}: {Reservable}, {nameof(ReservationTime)}: {ReservationTime}, {nameof(SimCard)}: ({SimCard}), {nameof(Roaming)}: {Roaming}, {nameof(LastConnectedAt)}: ({LastConnectedAt}), {nameof(DisconnectedAt)}: ({DisconnectedAt})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Consumer.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Consumer.verified.cs index e471363c9..7d9cad421 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Consumer.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Consumer.verified.cs @@ -24,7 +24,13 @@ public class Consumer public long OperatorId { get; set; } /// - /// List of team ids that are unlocked for API operations. If empty, all teams of this operator are unlocked. + /// List of operator ids that are authorized for API operations. If empty, all child operators of this operator are authorized. + /// + [Required] + public List OperatorIds { get; set; } + + /// + /// List of team ids that are authorized for API operations. If empty, all teams of this operator are authorized. /// [Required] public List TeamIds { get; set; } @@ -64,5 +70,5 @@ public class Consumer /// public override string ToString() - => $"{nameof(Name)}: {Name}, {nameof(OperatorId)}: {OperatorId}, {nameof(TeamIds)}.Count: {TeamIds?.Count ?? 0}, {nameof(ClientId)}: {ClientId}, {nameof(RateLimit)}: {RateLimit}, {nameof(RateLimitIntervalInSeconds)}: {RateLimitIntervalInSeconds}, {nameof(Scopes)}.Count: {Scopes?.Count ?? 0}, {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt})"; + => $"{nameof(Name)}: {Name}, {nameof(OperatorId)}: {OperatorId}, {nameof(OperatorIds)}.Count: {OperatorIds?.Count ?? 0}, {nameof(TeamIds)}.Count: {TeamIds?.Count ?? 0}, {nameof(ClientId)}: {ClientId}, {nameof(RateLimit)}: {RateLimit}, {nameof(RateLimitIntervalInSeconds)}: {RateLimitIntervalInSeconds}, {nameof(Scopes)}.Count: {Scopes?.Count ?? 0}, {nameof(CreatedAt)}: ({CreatedAt}), {nameof(UpdatedAt)}: ({UpdatedAt})"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/CreatedOrUpdateAddress.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/CreatedOrUpdateAddress.verified.cs index b335234f8..2daacc138 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/CreatedOrUpdateAddress.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/CreatedOrUpdateAddress.verified.cs @@ -22,13 +22,11 @@ public class CreatedOrUpdateAddress /// /// Second line of address. /// - [MinLength(1)] public string? Address2 { get; set; } /// /// Third line of address. /// - [MinLength(1)] public string? Address3 { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Currency.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Currency.verified.cs index adbdb1c9e..2a7af6fb6 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Currency.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Currency.verified.cs @@ -13,23 +13,37 @@ namespace Monta.ApiClient.Generated.Contracts; public class Currency { /// - /// Currency identifier, e.g. dkk. + /// id of the currency. + /// + [Range(0, int.MaxValue)] + public long? Id { get; set; } + + /// + /// Whether the currency is master or not, master meaning the default currency. + /// + public bool Master { get; set; } + + /// + /// 3 characters identifier. /// [Required] + [MinLength(3)] + [MaxLength(3)] public string Identifier { get; set; } /// - /// Readable name of currency. + /// Name of the currency. /// - [Required] public string Name { get; set; } /// - /// Number of decimals for this currency. + /// How many decimals the currency has. /// + [Required] + [Range(0, int.MaxValue)] public int Decimals { get; set; } /// public override string ToString() - => $"{nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; + => $"{nameof(Id)}: {Id}, {nameof(Master)}: {Master}, {nameof(Identifier)}: {Identifier}, {nameof(Name)}: {Name}, {nameof(Decimals)}: {Decimals}"; } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/CurrencyDto3.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/CurrencyDto.verified.cs similarity index 87% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/CurrencyDto3.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/CurrencyDto.verified.cs index f0572d35d..52c77cac8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/Currencies/CurrencyDto3.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/CurrencyDto.verified.cs @@ -4,13 +4,13 @@ // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. //------------------------------------------------------------------------------ -namespace Monta.ApiClient.Generated.Contracts.Currencies; +namespace Monta.ApiClient.Generated.Contracts; /// -/// CurrencyDto3. +/// CurrencyDto. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public class CurrencyDto3 +public class CurrencyDto { /// /// id of the currency. @@ -19,7 +19,7 @@ public class CurrencyDto3 public long? Id { get; set; } /// - /// Currency identifier, e.g. DKK. + /// Currency identifier. /// public string? Identifier { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Location.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Location.verified.cs index 23387956f..beed3aa17 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Location.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Location.verified.cs @@ -12,8 +12,14 @@ namespace Monta.ApiClient.Generated.Contracts; [GeneratedCode("ApiGenerator", "x.x.x.x")] public class Location { + /// + /// Coordinates (lat, lng). + /// public Coordinates? Coordinates { get; set; } + /// + /// Address. + /// public Address? Address { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Money.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Money.verified.cs index 9816fd0e6..2c5b7db40 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Money.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Money.verified.cs @@ -18,6 +18,9 @@ public class Money [Required] public long Amount { get; set; } + /// + /// Currency. + /// [Required] public Currency Currency { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Pageable.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Pageable.verified.cs new file mode 100644 index 000000000..8fc25027e --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Pageable.verified.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts; + +/// +/// Pageable. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class Pageable +{ + /// + /// A list of Pageable. + /// + public List PageableList { get; set; } = new List(); + + /// + public override string ToString() + => $"{nameof(PageableList)}.Count: {PageableList?.Count ?? 0}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PriceGroup.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PriceGroup.verified.cs index c2b3ad363..ffc847e96 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PriceGroup.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PriceGroup.verified.cs @@ -27,9 +27,15 @@ public class PriceGroup public bool Default { get; set; } + /// + /// Type of the price group. + /// [Required] public PriceGroupType Type { get; set; } + /// + /// The master price. + /// [Required] public Pricing MasterPrice { get; set; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PriceGroupTag.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PriceGroupTag.verified.cs index 8a214ed20..291723d80 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PriceGroupTag.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/PriceGroupTag.verified.cs @@ -38,6 +38,9 @@ public class PriceGroupTag /// public List? PartnerCustomPayload { get; set; } = new List(); + /// + /// The operator to which this resource belongs to. + /// public Operator? Operator { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Pricing.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Pricing.verified.cs index 191b4b257..f83b1bc59 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Pricing.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Pricing.verified.cs @@ -24,6 +24,9 @@ public class Pricing /// public string? Description { get; set; } + /// + /// Type of the pricing. `minute` is used for Minute fee. `min` is used for the master price. + /// [Required] public PricingType Type { get; set; } @@ -54,7 +57,7 @@ public class Pricing /// /// Used by Spot Price. It will multiply the fallback price by this percentage. /// - public double? Percentage { get; set; } = 100.000; + public double? Percentage { get; set; } /// /// The id of the selected Tariff. @@ -72,13 +75,25 @@ public class Pricing /// public int? ApplyAfterMinutes { get; set; } + /// + /// The price of this Fee or Master price. + /// [Required] public Money Price { get; set; } + /// + /// Used by spot price. The minimum that the raw spot price can be. This will be used in calculations if spot price is lower than this. + /// public Money? PriceMin { get; set; } + /// + /// Used by spot price. The maximum that the raw spot price can be. This will be used in calculations if spot price is higher than this. + /// public Money? PriceMax { get; set; } + /// + /// Used by Idle fee. The maximum the user will be charged for the idle fee. + /// public Money? FeePriceMax { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/SimCard.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/SimCard.verified.cs new file mode 100644 index 000000000..28f92cbb8 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/SimCard.verified.cs @@ -0,0 +1,28 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Contracts; + +/// +/// SimCard. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class SimCard +{ + /// + /// imsi (International Mobile Subscriber Identity) for the SIM card. + /// + public string? Imsi { get; set; } + + /// + /// iccid (Integrated Circuit Card Identifier) for the SIM card. + /// + public string? Iccid { get; set; } + + /// + public override string ToString() + => $"{nameof(Imsi)}: {Imsi}, {nameof(Iccid)}: {Iccid}"; +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Subscription.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Subscription.verified.cs index 872ac62af..42feca760 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Subscription.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Contracts/_Shared/Subscription.verified.cs @@ -17,6 +17,9 @@ public class Subscription /// public long Id { get; set; } + /// + /// State of the subscription. + /// [Required] public SubscriptionState State { get; set; } @@ -75,6 +78,9 @@ public class Subscription /// public long CustomerId { get; set; } + /// + /// Customer type. + /// [Required] public SubscriptionCustomerType CustomerType { get; set; } @@ -83,6 +89,9 @@ public class Subscription /// public long PlanId { get; set; } + /// + /// Subscription configuration, based on the plans serviceType.Currently you can configure tax-refund subscriptions only. + /// public SubscriptionServiceConfig? ServiceConfig { get; set; } /// diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/BlockChargeAuthTokenEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/BlockChargeAuthTokenEndpoint.verified.cs index b2472f42f..643d55259 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/BlockChargeAuthTokenEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/BlockChargeAuthTokenEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new BlockChargeAuthTokenEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/BlockChargeAuthTokenEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/BlockChargeAuthTokenEndpointResult.verified.cs index b7485f4da..daba81998 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/BlockChargeAuthTokenEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/BlockChargeAuthTokenEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public ChargeAuthToken OkContent => IsOk && ContentObject is ChargeAuthToken result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/CreateChargeAuthTokenEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/CreateChargeAuthTokenEndpoint.verified.cs index 2e9f3aa90..dc15e49a3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/CreateChargeAuthTokenEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/CreateChargeAuthTokenEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new CreateChargeAuthTokenEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/CreateChargeAuthTokenEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/CreateChargeAuthTokenEndpointResult.verified.cs index ad8a36b7a..f1b3a145f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/CreateChargeAuthTokenEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/CreateChargeAuthTokenEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/GetChargeAuthTokensEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/GetChargeAuthTokensEndpoint.verified.cs index 5b2caa4be..b5cefdfc0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/GetChargeAuthTokensEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/GetChargeAuthTokensEndpoint.verified.cs @@ -45,6 +45,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetChargeAuthTokensEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/GetChargeAuthTokensEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/GetChargeAuthTokensEndpointResult.verified.cs index 5e4f8add2..bd2d9ac85 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/GetChargeAuthTokensEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/GetChargeAuthTokensEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargeAuthTokenDto OkContent => IsOk && ContentObject is MontaPageChargeAuthTokenDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IBlockChargeAuthTokenEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IBlockChargeAuthTokenEndpointResult.verified.cs index 6c00d3726..9b3a33b64 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IBlockChargeAuthTokenEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IBlockChargeAuthTokenEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IBlockChargeAuthTokenEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + ChargeAuthToken OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IBlockChargeAuthTokenEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/ICreateChargeAuthTokenEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/ICreateChargeAuthTokenEndpointResult.verified.cs index 28f585191..04dae2c6a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/ICreateChargeAuthTokenEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/ICreateChargeAuthTokenEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface ICreateChargeAuthTokenEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface ICreateChargeAuthTokenEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IGetChargeAuthTokensEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IGetChargeAuthTokensEndpointResult.verified.cs index da853d54e..70134a8f0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IGetChargeAuthTokensEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IGetChargeAuthTokensEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetChargeAuthTokensEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargeAuthTokenDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IPatchChargeAuthTokenEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IPatchChargeAuthTokenEndpointResult.verified.cs index 4611f2d3a..4b0a2cddf 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IPatchChargeAuthTokenEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IPatchChargeAuthTokenEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPatchChargeAuthTokenEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + ChargeAuthToken OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPatchChargeAuthTokenEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IUnblockChargeAuthTokenEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IUnblockChargeAuthTokenEndpointResult.verified.cs index 1e547ea53..87c60701d 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IUnblockChargeAuthTokenEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/Interfaces/IUnblockChargeAuthTokenEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IUnblockChargeAuthTokenEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + ChargeAuthToken OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IUnblockChargeAuthTokenEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/PatchChargeAuthTokenEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/PatchChargeAuthTokenEndpoint.verified.cs index e755b5322..e1f7d9d99 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/PatchChargeAuthTokenEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/PatchChargeAuthTokenEndpoint.verified.cs @@ -44,6 +44,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PatchChargeAuthTokenEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/PatchChargeAuthTokenEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/PatchChargeAuthTokenEndpointResult.verified.cs index 6c9726fb3..07be2d44d 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/PatchChargeAuthTokenEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/PatchChargeAuthTokenEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public ChargeAuthToken OkContent => IsOk && ContentObject is ChargeAuthToken result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/UnblockChargeAuthTokenEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/UnblockChargeAuthTokenEndpoint.verified.cs index 3ac235179..048b5c58c 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/UnblockChargeAuthTokenEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/UnblockChargeAuthTokenEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new UnblockChargeAuthTokenEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/UnblockChargeAuthTokenEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/UnblockChargeAuthTokenEndpointResult.verified.cs index 70e10fc70..3365db4ef 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/UnblockChargeAuthTokenEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargeAuthTokens/UnblockChargeAuthTokenEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public ChargeAuthToken OkContent => IsOk && ContentObject is ChargeAuthToken result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/GetChargePointBrandsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/GetChargePointBrandsEndpoint.verified.cs index 5ea6c0ed2..d4cf385f0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/GetChargePointBrandsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/GetChargePointBrandsEndpoint.verified.cs @@ -44,6 +44,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetChargePointBrandsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/GetChargePointBrandsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/GetChargePointBrandsEndpointResult.verified.cs index 73bec3f9e..d8cbe9b9d 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/GetChargePointBrandsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/GetChargePointBrandsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargePointBrandDto OkContent => IsOk && ContentObject is MontaPageChargePointBrandDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/Interfaces/IGetChargePointBrandsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/Interfaces/IGetChargePointBrandsEndpointResult.verified.cs index df41ae397..88c1866f9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/Interfaces/IGetChargePointBrandsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointBrands/Interfaces/IGetChargePointBrandsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetChargePointBrandsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargePointBrandDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/GetConnectorsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/GetConnectorsEndpoint.verified.cs index 0548d2ad1..e209e6f71 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/GetConnectorsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/GetConnectorsEndpoint.verified.cs @@ -40,6 +40,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetConnectorsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/GetConnectorsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/GetConnectorsEndpointResult.verified.cs index 52ef19bc6..5affa8809 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/GetConnectorsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/GetConnectorsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargePointConnectorDto OkContent => IsOk && ContentObject is MontaPageChargePointConnectorDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/Interfaces/IGetConnectorsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/Interfaces/IGetConnectorsEndpointResult.verified.cs index 762365c06..11a96d17f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/Interfaces/IGetConnectorsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointConnectors/Interfaces/IGetConnectorsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetConnectorsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargePointConnectorDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/GetChargePointIntegrationsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/GetChargePointIntegrationsEndpoint.verified.cs index 75749a1f8..56cc089b6 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/GetChargePointIntegrationsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/GetChargePointIntegrationsEndpoint.verified.cs @@ -45,6 +45,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetChargePointIntegrationsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/GetChargePointIntegrationsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/GetChargePointIntegrationsEndpointResult.verified.cs index fde3b4b4b..b4017d111 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/GetChargePointIntegrationsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/GetChargePointIntegrationsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargePointIntegrationDto OkContent => IsOk && ContentObject is MontaPageChargePointIntegrationDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/Interfaces/IGetChargePointIntegrationsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/Interfaces/IGetChargePointIntegrationsEndpointResult.verified.cs index 27cf6cfdc..81accc2b8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/Interfaces/IGetChargePointIntegrationsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/Interfaces/IGetChargePointIntegrationsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetChargePointIntegrationsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargePointIntegrationDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/Interfaces/IPostOrPutChargePointIntegrationEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/Interfaces/IPostOrPutChargePointIntegrationEndpointResult.verified.cs index e4a4b20fa..50b749638 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/Interfaces/IPostOrPutChargePointIntegrationEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/Interfaces/IPostOrPutChargePointIntegrationEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPostOrPutChargePointIntegrationEndpointResult : IEndpointRespo bool IsForbidden { get; } + bool IsNotFound { get; } + ChargePointIntegration OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPostOrPutChargePointIntegrationEndpointResult : IEndpointRespo string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/PostOrPutChargePointIntegrationEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/PostOrPutChargePointIntegrationEndpoint.verified.cs index 39fc068ff..b82b25c8a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/PostOrPutChargePointIntegrationEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/PostOrPutChargePointIntegrationEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PostOrPutChargePointIntegrationEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/PostOrPutChargePointIntegrationEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/PostOrPutChargePointIntegrationEndpointResult.verified.cs index 53980c0f3..ad4d4bd7a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/PostOrPutChargePointIntegrationEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointIntegrations/PostOrPutChargePointIntegrationEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public ChargePointIntegration OkContent => IsOk && ContentObject is ChargePointIntegration result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/GetChargePointModelsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/GetChargePointModelsEndpoint.verified.cs index 99833b27c..49abd2b93 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/GetChargePointModelsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/GetChargePointModelsEndpoint.verified.cs @@ -45,6 +45,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetChargePointModelsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/GetChargePointModelsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/GetChargePointModelsEndpointResult.verified.cs index 0644c6bab..fc90ddd58 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/GetChargePointModelsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/GetChargePointModelsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargePointModelDto OkContent => IsOk && ContentObject is MontaPageChargePointModelDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/Interfaces/IGetChargePointModelsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/Interfaces/IGetChargePointModelsEndpointResult.verified.cs index 9c213bbc4..aab3e6d15 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/Interfaces/IGetChargePointModelsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointModels/Interfaces/IGetChargePointModelsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetChargePointModelsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargePointModelDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetChargePointStatisticsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetChargePointStatisticsEndpoint.verified.cs new file mode 100644 index 000000000..5dac0bf08 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetChargePointStatisticsEndpoint.verified.cs @@ -0,0 +1,51 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePointStatistics; + +/// +/// Client Endpoint. +/// Description: Retrieve statistics related to a charge point. +/// Operation: GetChargePointStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetChargePointStatisticsEndpoint : IGetChargePointStatisticsEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetChargePointStatisticsEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetChargePointStatisticsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/charge-point-statistics/by-charge-point"); + requestBuilder.WithQueryParameter("chargePointId", parameters.ChargePointId); + requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); + requestBuilder.WithQueryParameter("toDate", parameters.ToDate); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetChargePointStatisticsEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetChargePointStatisticsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetChargePointStatisticsEndpointResult.verified.cs new file mode 100644 index 000000000..86c0d5e8a --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetChargePointStatisticsEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePointStatistics; + +/// +/// Client Endpoint result. +/// Description: Retrieve statistics related to a charge point. +/// Operation: GetChargePointStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetChargePointStatisticsEndpointResult : EndpointResponse, IGetChargePointStatisticsEndpointResult +{ + public GetChargePointStatisticsEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public ChargePointStatisticsDto OkContent + => IsOk && ContentObject is ChargePointStatisticsDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetSiteStatisticsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetSiteStatisticsEndpoint.verified.cs new file mode 100644 index 000000000..922a8a713 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetSiteStatisticsEndpoint.verified.cs @@ -0,0 +1,51 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePointStatistics; + +/// +/// Client Endpoint. +/// Description: Retrieve statistics related to a site. +/// Operation: GetSiteStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetSiteStatisticsEndpoint : IGetSiteStatisticsEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetSiteStatisticsEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetSiteStatisticsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/charge-point-statistics/by-site"); + requestBuilder.WithQueryParameter("siteId", parameters.SiteId); + requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); + requestBuilder.WithQueryParameter("toDate", parameters.ToDate); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetSiteStatisticsEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetSiteStatisticsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetSiteStatisticsEndpointResult.verified.cs new file mode 100644 index 000000000..6e5037db1 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/GetSiteStatisticsEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePointStatistics; + +/// +/// Client Endpoint result. +/// Description: Retrieve statistics related to a site. +/// Operation: GetSiteStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetSiteStatisticsEndpointResult : EndpointResponse, IGetSiteStatisticsEndpointResult +{ + public GetSiteStatisticsEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public ChargePointStatisticsDto OkContent + => IsOk && ContentObject is ChargePointStatisticsDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetChargePointStatisticsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetChargePointStatisticsEndpoint.verified.cs new file mode 100644 index 000000000..ea9a2eef8 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetChargePointStatisticsEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePointStatistics.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve statistics related to a charge point. +/// Operation: GetChargePointStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetChargePointStatisticsEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetChargePointStatisticsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetChargePointStatisticsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetChargePointStatisticsEndpointResult.verified.cs new file mode 100644 index 000000000..38add9a7a --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetChargePointStatisticsEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePointStatistics.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve statistics related to a charge point. +/// Operation: GetChargePointStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetChargePointStatisticsEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + ChargePointStatisticsDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetSiteStatisticsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetSiteStatisticsEndpoint.verified.cs new file mode 100644 index 000000000..097e91b89 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetSiteStatisticsEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePointStatistics.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve statistics related to a site. +/// Operation: GetSiteStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetSiteStatisticsEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetSiteStatisticsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetSiteStatisticsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetSiteStatisticsEndpointResult.verified.cs new file mode 100644 index 000000000..9a6429ff0 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePointStatistics/Interfaces/IGetSiteStatisticsEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePointStatistics.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve statistics related to a site. +/// Operation: GetSiteStatistics. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetSiteStatisticsEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + ChargePointStatisticsDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/DeleteChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/DeleteChargePointEndpoint.verified.cs index 14813f54a..9b13ec105 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/DeleteChargePointEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/DeleteChargePointEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteChargePointEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/DeleteChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/DeleteChargePointEndpointResult.verified.cs index 516e86a0c..2d81a0486 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/DeleteChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/DeleteChargePointEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointMapEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointMapEndpoint.verified.cs index 181e6296f..ae6b33834 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointMapEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointMapEndpoint.verified.cs @@ -50,6 +50,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetChargePointMapEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointMapEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointMapEndpointResult.verified.cs index 5fb558655..fcaa09290 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointMapEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointMapEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MapResult OkContent => IsOk && ContentObject is MapResult result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointOcppLogsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointOcppLogsEndpoint.verified.cs new file mode 100644 index 000000000..8b0009a0d --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointOcppLogsEndpoint.verified.cs @@ -0,0 +1,53 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints; + +/// +/// Client Endpoint. +/// Description: Retrieve charge point OCPP logs. +/// Operation: GetChargePointOcppLogs. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetChargePointOcppLogsEndpoint : IGetChargePointOcppLogsEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetChargePointOcppLogsEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetChargePointOcppLogsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/charge-points/{chargePointId}/logs"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithPathParameter("chargePointId", parameters.ChargePointId); + requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); + requestBuilder.WithQueryParameter("toDate", parameters.ToDate); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetChargePointOcppLogsEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointOcppLogsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointOcppLogsEndpointResult.verified.cs new file mode 100644 index 000000000..94ad452a0 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointOcppLogsEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints; + +/// +/// Client Endpoint result. +/// Description: Retrieve charge point OCPP logs. +/// Operation: GetChargePointOcppLogs. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetChargePointOcppLogsEndpointResult : EndpointResponse, IGetChargePointOcppLogsEndpointResult +{ + public GetChargePointOcppLogsEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageChargePointOcppLogDto OkContent + => IsOk && ContentObject is MontaPageChargePointOcppLogDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointsEndpoint.verified.cs index 23b5072a1..9f4b548cd 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointsEndpoint.verified.cs @@ -39,7 +39,10 @@ public async Task ExecuteAsync( requestBuilder.WithQueryParameter("teamId", parameters.TeamId); requestBuilder.WithQueryParameter("partnerExternalId", parameters.PartnerExternalId); requestBuilder.WithQueryParameter("sortByLocation", parameters.SortByLocation); + requestBuilder.WithQueryParameter("boundingBox", parameters.BoundingBox); + requestBuilder.WithQueryParameter("operatorId", parameters.OperatorId); requestBuilder.WithQueryParameter("includeDeleted", parameters.IncludeDeleted); + requestBuilder.WithQueryParameter("includePublic", parameters.IncludePublic); requestBuilder.WithQueryParameter("state", parameters.State); using var requestMessage = requestBuilder.Build(HttpMethod.Get); @@ -49,6 +52,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetChargePointsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointsEndpointResult.verified.cs index 70a6d168a..fd3c705e3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/GetChargePointsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargePointDto OkContent => IsOk && ContentObject is MontaPageChargePointDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IDeleteChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IDeleteChargePointEndpointResult.verified.cs index d394e7706..3ddf113b7 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IDeleteChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IDeleteChargePointEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IDeleteChargePointEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IDeleteChargePointEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointMapEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointMapEndpointResult.verified.cs index 0c1b8f6b7..eef03b512 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointMapEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointMapEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetChargePointMapEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MapResult OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointOcppLogsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointOcppLogsEndpoint.verified.cs new file mode 100644 index 000000000..952217f99 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointOcppLogsEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve charge point OCPP logs. +/// Operation: GetChargePointOcppLogs. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetChargePointOcppLogsEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetChargePointOcppLogsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointOcppLogsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointOcppLogsEndpointResult.verified.cs new file mode 100644 index 000000000..fc4da2ad0 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointOcppLogsEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve charge point OCPP logs. +/// Operation: GetChargePointOcppLogs. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetChargePointOcppLogsEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + MontaPageChargePointOcppLogDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointsEndpointResult.verified.cs index 223882773..011127255 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IGetChargePointsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetChargePointsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargePointDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IPatchChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IPatchChargePointEndpointResult.verified.cs index aab2d7e72..4d4293332 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IPatchChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IPatchChargePointEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPatchChargePointEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + ChargePoint OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPatchChargePointEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IPostChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IPostChargePointEndpointResult.verified.cs index 446fee35f..ac40a19c9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IPostChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IPostChargePointEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPostChargePointEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPostChargePointEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IRebootChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IRebootChargePointEndpoint.verified.cs new file mode 100644 index 000000000..a9234f2ed --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IRebootChargePointEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Reboot an existing charge point. +/// Operation: RebootChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IRebootChargePointEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + RebootChargePointParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IRebootChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IRebootChargePointEndpointResult.verified.cs new file mode 100644 index 000000000..575a4b279 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IRebootChargePointEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Reboot an existing charge point. +/// Operation: RebootChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IRebootChargePointEndpointResult : IEndpointResponse +{ + + bool IsNoContent { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + string? NoContentContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IUnlockChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IUnlockChargePointEndpoint.verified.cs new file mode 100644 index 000000000..279ba9860 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IUnlockChargePointEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Unlock an existing charge point. +/// Operation: UnlockChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IUnlockChargePointEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + UnlockChargePointParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IUnlockChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IUnlockChargePointEndpointResult.verified.cs new file mode 100644 index 000000000..66157f065 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/Interfaces/IUnlockChargePointEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Unlock an existing charge point. +/// Operation: UnlockChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IUnlockChargePointEndpointResult : IEndpointResponse +{ + + bool IsNoContent { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + string? NoContentContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PatchChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PatchChargePointEndpoint.verified.cs index b4714c0fe..5574a69e5 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PatchChargePointEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PatchChargePointEndpoint.verified.cs @@ -44,6 +44,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PatchChargePointEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PatchChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PatchChargePointEndpointResult.verified.cs index 07dbab82a..04483b404 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PatchChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PatchChargePointEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public ChargePoint OkContent => IsOk && ContentObject is ChargePoint result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PostChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PostChargePointEndpoint.verified.cs index f87258bf6..2edc9ee10 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PostChargePointEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PostChargePointEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PostChargePointEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PostChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PostChargePointEndpointResult.verified.cs index 8683fa4f0..abd8b8ea6 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PostChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/PostChargePointEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/RebootChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/RebootChargePointEndpoint.verified.cs new file mode 100644 index 000000000..eb5493769 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/RebootChargePointEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints; + +/// +/// Client Endpoint. +/// Description: Reboot an existing charge point. +/// Operation: RebootChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class RebootChargePointEndpoint : IRebootChargePointEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public RebootChargePointEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + RebootChargePointParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/charge-points/{chargePointId}/reboot"); + requestBuilder.WithPathParameter("chargePointId", parameters.ChargePointId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Post); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new RebootChargePointEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/RebootChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/RebootChargePointEndpointResult.verified.cs new file mode 100644 index 000000000..875795bf7 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/RebootChargePointEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints; + +/// +/// Client Endpoint result. +/// Description: Reboot an existing charge point. +/// Operation: RebootChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class RebootChargePointEndpointResult : EndpointResponse, IRebootChargePointEndpointResult +{ + public RebootChargePointEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsNoContent + => StatusCode == HttpStatusCode.NoContent; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public string? NoContentContent + => IsNoContent && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNoContent property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/UnlockChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/UnlockChargePointEndpoint.verified.cs new file mode 100644 index 000000000..43c6674ed --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/UnlockChargePointEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints; + +/// +/// Client Endpoint. +/// Description: Unlock an existing charge point. +/// Operation: UnlockChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UnlockChargePointEndpoint : IUnlockChargePointEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public UnlockChargePointEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + UnlockChargePointParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/charge-points/{chargePointId}/unlock"); + requestBuilder.WithPathParameter("chargePointId", parameters.ChargePointId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Post); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new UnlockChargePointEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/UnlockChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/UnlockChargePointEndpointResult.verified.cs new file mode 100644 index 000000000..70bdc5669 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/ChargePoints/UnlockChargePointEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.ChargePoints; + +/// +/// Client Endpoint result. +/// Description: Unlock an existing charge point. +/// Operation: UnlockChargePoint. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UnlockChargePointEndpointResult : EndpointResponse, IUnlockChargePointEndpointResult +{ + public UnlockChargePointEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsNoContent + => StatusCode == HttpStatusCode.NoContent; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public string? NoContentContent + => IsNoContent && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNoContent property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargeBreakdownEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargeBreakdownEndpoint.verified.cs index c1e528177..f84392a0a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargeBreakdownEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargeBreakdownEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetChargeBreakdownEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargeBreakdownEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargeBreakdownEndpointResult.verified.cs index 2fe7098a3..687cf9672 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargeBreakdownEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargeBreakdownEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public ChargeBreakdown OkContent => IsOk && ContentObject is ChargeBreakdown result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargesEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargesEndpoint.verified.cs index 13f065843..8d9e63e8a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargesEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargesEndpoint.verified.cs @@ -36,6 +36,7 @@ public async Task ExecuteAsync( requestBuilder.WithQueryParameter("page", parameters.Page); requestBuilder.WithQueryParameter("perPage", parameters.PerPage); requestBuilder.WithQueryParameter("teamId", parameters.TeamId); + requestBuilder.WithQueryParameter("operatorId", parameters.OperatorId); requestBuilder.WithQueryParameter("chargePointId", parameters.ChargePointId); requestBuilder.WithQueryParameter("siteId", parameters.SiteId); requestBuilder.WithQueryParameter("state", parameters.State); @@ -53,6 +54,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetChargesEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargesEndpointResult.verified.cs index 3ee661c9f..501e86841 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/GetChargesEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargeDto OkContent => IsOk && ContentObject is MontaPageChargeDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IGetChargeBreakdownEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IGetChargeBreakdownEndpointResult.verified.cs index c2fbb15e5..329d6e2d2 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IGetChargeBreakdownEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IGetChargeBreakdownEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IGetChargeBreakdownEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + ChargeBreakdown OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IGetChargeBreakdownEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IGetChargesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IGetChargesEndpointResult.verified.cs index b065b0809..5301b320f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IGetChargesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IGetChargesEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetChargesEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargeDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IPatchChargeEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IPatchChargeEndpointResult.verified.cs index 41e6b7141..831e10a3c 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IPatchChargeEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IPatchChargeEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPatchChargeEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + Charge OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPatchChargeEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IStartChargeEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IStartChargeEndpointResult.verified.cs index 160a47d7a..e966deb42 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IStartChargeEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/Interfaces/IStartChargeEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IStartChargeEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } Charge OkContent { get; } @@ -29,5 +31,7 @@ public interface IStartChargeEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/PatchChargeEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/PatchChargeEndpoint.verified.cs index 994f61f26..6c37ae0ae 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/PatchChargeEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/PatchChargeEndpoint.verified.cs @@ -44,6 +44,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PatchChargeEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/PatchChargeEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/PatchChargeEndpointResult.verified.cs index 1d635086e..33d2868ef 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/PatchChargeEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/PatchChargeEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Charge OkContent => IsOk && ContentObject is Charge result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/StartChargeEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/StartChargeEndpoint.verified.cs index a6573bfe0..3a9265c9c 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/StartChargeEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/StartChargeEndpoint.verified.cs @@ -42,6 +42,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new StartChargeEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/StartChargeEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/StartChargeEndpointResult.verified.cs index ac0016e07..620b42ba1 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/StartChargeEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Charges/StartChargeEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/GetCurrentConsumerEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/GetCurrentConsumerEndpoint.verified.cs index 934fe0457..c555186f3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/GetCurrentConsumerEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/GetCurrentConsumerEndpoint.verified.cs @@ -40,6 +40,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetCurrentConsumerEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/GetCurrentConsumerEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/GetCurrentConsumerEndpointResult.verified.cs index 010c1ebf2..8d99384fe 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/GetCurrentConsumerEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/GetCurrentConsumerEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Consumer OkContent => IsOk && ContentObject is Consumer result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/Interfaces/IGetCurrentConsumerEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/Interfaces/IGetCurrentConsumerEndpointResult.verified.cs index c0fe007f8..c920230df 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/Interfaces/IGetCurrentConsumerEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Consumers/Interfaces/IGetCurrentConsumerEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetCurrentConsumerEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + Consumer OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountriesEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountriesEndpoint.verified.cs index c02ce017f..93e2ef8c5 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountriesEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountriesEndpoint.verified.cs @@ -40,6 +40,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetCountriesEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountriesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountriesEndpointResult.verified.cs index e951eb4eb..1998ade6e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountriesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountriesEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageCountryDto OkContent => IsOk && ContentObject is MontaPageCountryDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountryEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountryEndpoint.verified.cs index a86475ff5..d30535a0f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountryEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountryEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetCountryEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountryEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountryEndpointResult.verified.cs index fcdc17efe..3cb5175f9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountryEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/GetCountryEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Country OkContent => IsOk && ContentObject is Country result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/Interfaces/IGetCountriesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/Interfaces/IGetCountriesEndpointResult.verified.cs index 4e8705dbd..e0866b014 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/Interfaces/IGetCountriesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/Interfaces/IGetCountriesEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetCountriesEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageCountryDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/Interfaces/IGetCountryEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/Interfaces/IGetCountryEndpointResult.verified.cs index 337aebec7..ce57089cd 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/Interfaces/IGetCountryEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Countries/Interfaces/IGetCountryEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetCountryEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + Country OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountriesAreasEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountriesAreasEndpoint.verified.cs index 445b69bd7..dc12f0548 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountriesAreasEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountriesAreasEndpoint.verified.cs @@ -42,6 +42,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetCountriesAreasEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountriesAreasEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountriesAreasEndpointResult.verified.cs index b85b04675..f5984e754 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountriesAreasEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountriesAreasEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountryAreaEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountryAreaEndpoint.verified.cs index bef2b8b6b..df742c460 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountryAreaEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountryAreaEndpoint.verified.cs @@ -42,6 +42,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetCountryAreaEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountryAreaEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountryAreaEndpointResult.verified.cs index 02b9ecde8..d885af9fa 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountryAreaEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/GetCountryAreaEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/Interfaces/IGetCountriesAreasEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/Interfaces/IGetCountriesAreasEndpointResult.verified.cs index e5458ae98..c1d0f33a7 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/Interfaces/IGetCountriesAreasEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/Interfaces/IGetCountriesAreasEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IGetCountriesAreasEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } MontaPageCountryAreaDto OkContent { get; } @@ -29,5 +31,7 @@ public interface IGetCountriesAreasEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/Interfaces/IGetCountryAreaEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/Interfaces/IGetCountryAreaEndpointResult.verified.cs index cf505b53e..19cccd0ca 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/Interfaces/IGetCountryAreaEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/CountryAreas/Interfaces/IGetCountryAreaEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IGetCountryAreaEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } CountryArea OkContent { get; } @@ -29,5 +31,7 @@ public interface IGetCountryAreaEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrenciesEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrenciesEndpoint.verified.cs index 608982e70..886cd3d19 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrenciesEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrenciesEndpoint.verified.cs @@ -44,6 +44,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetCurrenciesEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrenciesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrenciesEndpointResult.verified.cs index 79a513b9a..fcb9efaf5 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrenciesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrenciesEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageCurrencyDto OkContent => IsOk && ContentObject is MontaPageCurrencyDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrencyEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrencyEndpoint.verified.cs index 3ed11111f..5ab04505e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrencyEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrencyEndpoint.verified.cs @@ -39,7 +39,7 @@ public async Task ExecuteAsync( using var response = await client.SendAsync(requestMessage, cancellationToken); var responseBuilder = httpMessageFactory.FromResponse(response); - responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrencyEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrencyEndpointResult.verified.cs index 472659e18..05f1bafa8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrencyEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/GetCurrencyEndpointResult.verified.cs @@ -34,8 +34,8 @@ public bool IsForbidden public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; - public CurrencyDto4 OkContent - => IsOk && ContentObject is CurrencyDto4 result + public CurrencyDto OkContent + => IsOk && ContentObject is CurrencyDto result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/Interfaces/IGetCurrenciesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/Interfaces/IGetCurrenciesEndpointResult.verified.cs index 05669c430..2218c3549 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/Interfaces/IGetCurrenciesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/Interfaces/IGetCurrenciesEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetCurrenciesEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageCurrencyDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/Interfaces/IGetCurrencyEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/Interfaces/IGetCurrencyEndpointResult.verified.cs index 60d5f8257..04b2381b8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/Interfaces/IGetCurrencyEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Currencies/Interfaces/IGetCurrencyEndpointResult.verified.cs @@ -25,7 +25,7 @@ public interface IGetCurrencyEndpointResult : IEndpointResponse bool IsNotFound { get; } - CurrencyDto4 OkContent { get; } + CurrencyDto OkContent { get; } string? BadRequestContent { get; } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargeAuthTokenReportEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargeAuthTokenReportEndpoint.verified.cs new file mode 100644 index 000000000..70b88aa73 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargeAuthTokenReportEndpoint.verified.cs @@ -0,0 +1,54 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Insights; + +/// +/// Client Endpoint. +/// Description: Retrieve insights about charges broken down by charge auth token and member cost groups of a team. +/// Operation: GetInsightsChargesChargeAuthTokenReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInsightsChargesChargeAuthTokenReportEndpoint : IGetInsightsChargesChargeAuthTokenReportEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetInsightsChargesChargeAuthTokenReportEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetInsightsChargesChargeAuthTokenReportParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/insights/charges/charge-auth-token-report"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithQueryParameter("teamId", parameters.TeamId); + requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); + requestBuilder.WithQueryParameter("toDate", parameters.ToDate); + requestBuilder.WithQueryParameter("datesFilteredBy", parameters.DatesFilteredBy); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetInsightsChargesChargeAuthTokenReportEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargeAuthTokenReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargeAuthTokenReportEndpointResult.verified.cs new file mode 100644 index 000000000..d17d8781e --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargeAuthTokenReportEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Insights; + +/// +/// Client Endpoint result. +/// Description: Retrieve insights about charges broken down by charge auth token and member cost groups of a team. +/// Operation: GetInsightsChargesChargeAuthTokenReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInsightsChargesChargeAuthTokenReportEndpointResult : EndpointResponse, IGetInsightsChargesChargeAuthTokenReportEndpointResult +{ + public GetInsightsChargesChargeAuthTokenReportEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageChargesInsightByChargeAuthTokenReportDto OkContent + => IsOk && ContentObject is MontaPageChargesInsightByChargeAuthTokenReportDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargerReportEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargerReportEndpoint.verified.cs index ef56f58e6..bd78b64d0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargerReportEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargerReportEndpoint.verified.cs @@ -33,6 +33,8 @@ public async Task ExecuteAsync( var client = factory.CreateClient(httpClientName); var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/insights/charges/charger-report"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); requestBuilder.WithQueryParameter("teamId", parameters.TeamId); requestBuilder.WithQueryParameter("chargePointIds", parameters.ChargePointIds); requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); @@ -45,6 +47,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetInsightsChargesChargerReportEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargerReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargerReportEndpointResult.verified.cs index 3cd3c8ba2..68aed7a20 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargerReportEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesChargerReportEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargesInsightChargerReportDto OkContent => IsOk && ContentObject is MontaPageChargesInsightChargerReportDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverMemberCostsReportEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverMemberCostsReportEndpoint.verified.cs new file mode 100644 index 000000000..f44b00818 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverMemberCostsReportEndpoint.verified.cs @@ -0,0 +1,55 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Insights; + +/// +/// Client Endpoint. +/// Description: Retrieve insights about charges broken down by team members and member cost groups of a team. +/// Operation: GetInsightsChargesDriverMemberCostsReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInsightsChargesDriverMemberCostsReportEndpoint : IGetInsightsChargesDriverMemberCostsReportEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetInsightsChargesDriverMemberCostsReportEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetInsightsChargesDriverMemberCostsReportParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/insights/charges/driver-member-costs-report"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithQueryParameter("teamId", parameters.TeamId); + requestBuilder.WithQueryParameter("teamMemberIds", parameters.TeamMemberIds); + requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); + requestBuilder.WithQueryParameter("toDate", parameters.ToDate); + requestBuilder.WithQueryParameter("datesFilteredBy", parameters.DatesFilteredBy); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetInsightsChargesDriverMemberCostsReportEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverMemberCostsReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverMemberCostsReportEndpointResult.verified.cs new file mode 100644 index 000000000..cfb0e8052 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverMemberCostsReportEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Insights; + +/// +/// Client Endpoint result. +/// Description: Retrieve insights about charges broken down by team members and member cost groups of a team. +/// Operation: GetInsightsChargesDriverMemberCostsReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInsightsChargesDriverMemberCostsReportEndpointResult : EndpointResponse, IGetInsightsChargesDriverMemberCostsReportEndpointResult +{ + public GetInsightsChargesDriverMemberCostsReportEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageChargesInsightDriverMemberCostsReportDto OkContent + => IsOk && ContentObject is MontaPageChargesInsightDriverMemberCostsReportDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverReportEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverReportEndpoint.verified.cs index 579d0409f..dd93eb5c0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverReportEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverReportEndpoint.verified.cs @@ -33,6 +33,8 @@ public async Task ExecuteAsync( var client = factory.CreateClient(httpClientName); var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/insights/charges/driver-report"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); requestBuilder.WithQueryParameter("teamId", parameters.TeamId); requestBuilder.WithQueryParameter("teamMemberIds", parameters.TeamMemberIds); requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); @@ -46,6 +48,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetInsightsChargesDriverReportEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverReportEndpointResult.verified.cs index c29f024ab..5c74a8d64 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverReportEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/GetInsightsChargesDriverReportEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageChargesInsightDriverReportDto OkContent => IsOk && ContentObject is MontaPageChargesInsightDriverReportDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargeAuthTokenReportEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargeAuthTokenReportEndpoint.verified.cs new file mode 100644 index 000000000..1bfdc876c --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargeAuthTokenReportEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Insights.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve insights about charges broken down by charge auth token and member cost groups of a team. +/// Operation: GetInsightsChargesChargeAuthTokenReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetInsightsChargesChargeAuthTokenReportEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetInsightsChargesChargeAuthTokenReportParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargeAuthTokenReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargeAuthTokenReportEndpointResult.verified.cs new file mode 100644 index 000000000..5a9c8da5f --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargeAuthTokenReportEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Insights.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve insights about charges broken down by charge auth token and member cost groups of a team. +/// Operation: GetInsightsChargesChargeAuthTokenReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetInsightsChargesChargeAuthTokenReportEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + MontaPageChargesInsightByChargeAuthTokenReportDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargerReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargerReportEndpointResult.verified.cs index 8a05a2f43..a2f874830 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargerReportEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesChargerReportEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetInsightsChargesChargerReportEndpointResult : IEndpointRespo bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargesInsightChargerReportDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverMemberCostsReportEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverMemberCostsReportEndpoint.verified.cs new file mode 100644 index 000000000..7ab419703 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverMemberCostsReportEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Insights.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve insights about charges broken down by team members and member cost groups of a team. +/// Operation: GetInsightsChargesDriverMemberCostsReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetInsightsChargesDriverMemberCostsReportEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetInsightsChargesDriverMemberCostsReportParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverMemberCostsReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverMemberCostsReportEndpointResult.verified.cs new file mode 100644 index 000000000..0aa4a865d --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverMemberCostsReportEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Insights.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve insights about charges broken down by team members and member cost groups of a team. +/// Operation: GetInsightsChargesDriverMemberCostsReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetInsightsChargesDriverMemberCostsReportEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + MontaPageChargesInsightDriverMemberCostsReportDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverReportEndpointResult.verified.cs index 85124d221..3408a34a9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverReportEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Insights/Interfaces/IGetInsightsChargesDriverReportEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetInsightsChargesDriverReportEndpointResult : IEndpointRespon bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageChargesInsightDriverReportDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/DeleteInstallerJobEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/DeleteInstallerJobEndpoint.verified.cs index 03715389f..4fc0ee547 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/DeleteInstallerJobEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/DeleteInstallerJobEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteInstallerJobEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/DeleteInstallerJobEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/DeleteInstallerJobEndpointResult.verified.cs index b6535bfa1..41b10651e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/DeleteInstallerJobEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/DeleteInstallerJobEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/GetInstallerJobsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/GetInstallerJobsEndpoint.verified.cs index 35ed00c79..11426d0f4 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/GetInstallerJobsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/GetInstallerJobsEndpoint.verified.cs @@ -46,6 +46,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetInstallerJobsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/GetInstallerJobsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/GetInstallerJobsEndpointResult.verified.cs index f2ebebe9b..ba7ed8d9f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/GetInstallerJobsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/GetInstallerJobsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageInstallerJobDto OkContent => IsOk && ContentObject is MontaPageInstallerJobDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IDeleteInstallerJobEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IDeleteInstallerJobEndpointResult.verified.cs index a2996aaf0..be48cb95f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IDeleteInstallerJobEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IDeleteInstallerJobEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IDeleteInstallerJobEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IDeleteInstallerJobEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IGetInstallerJobsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IGetInstallerJobsEndpointResult.verified.cs index 9b65deab8..f5fcde7c2 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IGetInstallerJobsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IGetInstallerJobsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetInstallerJobsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageInstallerJobDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IPostInstallerJobEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IPostInstallerJobEndpointResult.verified.cs index b8bcb35a6..d8f77038f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IPostInstallerJobEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/Interfaces/IPostInstallerJobEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPostInstallerJobEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPostInstallerJobEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/PostInstallerJobEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/PostInstallerJobEndpoint.verified.cs index 2186615de..27445affb 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/PostInstallerJobEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/PostInstallerJobEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PostInstallerJobEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/PostInstallerJobEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/PostInstallerJobEndpointResult.verified.cs index e5b032344..d60e62235 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/PostInstallerJobEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/InstallerJobs/PostInstallerJobEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoice1Endpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoice1Endpoint.verified.cs new file mode 100644 index 000000000..cd83b2176 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoice1Endpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Invoices; + +/// +/// Client Endpoint. +/// Description: Retrieves an invoice by its id. +/// Operation: GetInvoice1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInvoice1Endpoint : IGetInvoice1Endpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetInvoice1Endpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetInvoice1Parameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/invoices/{invoiceId}"); + requestBuilder.WithPathParameter("invoiceId", parameters.InvoiceId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetInvoice1EndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoice1EndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoice1EndpointResult.verified.cs new file mode 100644 index 000000000..74b8b8018 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoice1EndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Invoices; + +/// +/// Client Endpoint result. +/// Description: Retrieves an invoice by its id. +/// Operation: GetInvoice1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInvoice1EndpointResult : EndpointResponse, IGetInvoice1EndpointResult +{ + public GetInvoice1EndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public InvoiceDto OkContent + => IsOk && ContentObject is InvoiceDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoiceEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoiceEndpoint.verified.cs new file mode 100644 index 000000000..71b335d06 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoiceEndpoint.verified.cs @@ -0,0 +1,52 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Invoices; + +/// +/// Client Endpoint. +/// Description: Retrieves a list of invoices by walletId. +/// Operation: GetInvoice. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInvoiceEndpoint : IGetInvoiceEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetInvoiceEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetInvoiceParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/invoices"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithQueryParameter("walletId", parameters.WalletId); + requestBuilder.WithQueryParameter("pageable", parameters.Pageable); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetInvoiceEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoiceEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoiceEndpointResult.verified.cs new file mode 100644 index 000000000..0bf730b8d --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/GetInvoiceEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Invoices; + +/// +/// Client Endpoint result. +/// Description: Retrieves a list of invoices by walletId. +/// Operation: GetInvoice. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetInvoiceEndpointResult : EndpointResponse, IGetInvoiceEndpointResult +{ + public GetInvoiceEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageInvoiceDto OkContent + => IsOk && ContentObject is MontaPageInvoiceDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoice1Endpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoice1Endpoint.verified.cs new file mode 100644 index 000000000..7ba6394a1 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoice1Endpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Invoices.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieves an invoice by its id. +/// Operation: GetInvoice1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetInvoice1Endpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetInvoice1Parameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoice1EndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoice1EndpointResult.verified.cs new file mode 100644 index 000000000..ccb3d2528 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoice1EndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Invoices.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieves an invoice by its id. +/// Operation: GetInvoice1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetInvoice1EndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + InvoiceDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoiceEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoiceEndpoint.verified.cs new file mode 100644 index 000000000..18515fa66 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoiceEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Invoices.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieves a list of invoices by walletId. +/// Operation: GetInvoice. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetInvoiceEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetInvoiceParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoiceEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoiceEndpointResult.verified.cs new file mode 100644 index 000000000..3ac24b059 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Invoices/Interfaces/IGetInvoiceEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Invoices.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieves a list of invoices by walletId. +/// Operation: GetInvoice. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetInvoiceEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + MontaPageInvoiceDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/AcceptInviteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/AcceptInviteEndpoint.verified.cs new file mode 100644 index 000000000..6c1499b98 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/AcceptInviteEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint. +/// Description: Accept a nested team invitation. +/// Operation: AcceptInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class AcceptInviteEndpoint : IAcceptInviteEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public AcceptInviteEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + AcceptInviteParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/nested-teams/{relationId}/accept-invite"); + requestBuilder.WithPathParameter("relationId", parameters.RelationId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Post); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new AcceptInviteEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/AcceptInviteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/AcceptInviteEndpointResult.verified.cs new file mode 100644 index 000000000..a19feeebd --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/AcceptInviteEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint result. +/// Description: Accept a nested team invitation. +/// Operation: AcceptInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class AcceptInviteEndpointResult : EndpointResponse, IAcceptInviteEndpointResult +{ + public AcceptInviteEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public NestedTeam OkContent + => IsOk && ContentObject is NestedTeam result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/DeleteNestedTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/DeleteNestedTeamEndpoint.verified.cs new file mode 100644 index 000000000..ba1ae2a25 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/DeleteNestedTeamEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint. +/// Description: Delete a nested team relation. +/// Operation: DeleteNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class DeleteNestedTeamEndpoint : IDeleteNestedTeamEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public DeleteNestedTeamEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + DeleteNestedTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/nested-teams/{relationId}"); + requestBuilder.WithPathParameter("relationId", parameters.RelationId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Delete); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new DeleteNestedTeamEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/DeleteNestedTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/DeleteNestedTeamEndpointResult.verified.cs new file mode 100644 index 000000000..453267e1d --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/DeleteNestedTeamEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint result. +/// Description: Delete a nested team relation. +/// Operation: DeleteNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class DeleteNestedTeamEndpointResult : EndpointResponse, IDeleteNestedTeamEndpointResult +{ + public DeleteNestedTeamEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsNoContent + => StatusCode == HttpStatusCode.NoContent; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public string? NoContentContent + => IsNoContent && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNoContent property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamEndpoint.verified.cs new file mode 100644 index 000000000..67074bd8e --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint. +/// Description: Get a nested team by nested team relation id. +/// Operation: GetNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetNestedTeamEndpoint : IGetNestedTeamEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetNestedTeamEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetNestedTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/nested-teams/{relationId}"); + requestBuilder.WithPathParameter("relationId", parameters.RelationId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetNestedTeamEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamEndpointResult.verified.cs new file mode 100644 index 000000000..b838c1510 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint result. +/// Description: Get a nested team by nested team relation id. +/// Operation: GetNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetNestedTeamEndpointResult : EndpointResponse, IGetNestedTeamEndpointResult +{ + public GetNestedTeamEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public NestedTeam OkContent + => IsOk && ContentObject is NestedTeam result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamsEndpoint.verified.cs new file mode 100644 index 000000000..781370153 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamsEndpoint.verified.cs @@ -0,0 +1,52 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint. +/// Description: Retrieve a list of nested team relations. +/// Operation: GetNestedTeams. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetNestedTeamsEndpoint : IGetNestedTeamsEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetNestedTeamsEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetNestedTeamsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/nested-teams"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithQueryParameter("state", parameters.State); + requestBuilder.WithQueryParameter("includeDeleted", parameters.IncludeDeleted); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetNestedTeamsEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamsEndpointResult.verified.cs new file mode 100644 index 000000000..e3d065c58 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/GetNestedTeamsEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint result. +/// Description: Retrieve a list of nested team relations. +/// Operation: GetNestedTeams. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetNestedTeamsEndpointResult : EndpointResponse, IGetNestedTeamsEndpointResult +{ + public GetNestedTeamsEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageNestedTeamDto OkContent + => IsOk && ContentObject is MontaPageNestedTeamDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IAcceptInviteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IAcceptInviteEndpoint.verified.cs new file mode 100644 index 000000000..6ad9637fe --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IAcceptInviteEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Accept a nested team invitation. +/// Operation: AcceptInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IAcceptInviteEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + AcceptInviteParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IAcceptInviteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IAcceptInviteEndpointResult.verified.cs new file mode 100644 index 000000000..e07200024 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IAcceptInviteEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Accept a nested team invitation. +/// Operation: AcceptInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IAcceptInviteEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + NestedTeam OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IDeleteNestedTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IDeleteNestedTeamEndpoint.verified.cs new file mode 100644 index 000000000..0e13f22c6 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IDeleteNestedTeamEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Delete a nested team relation. +/// Operation: DeleteNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IDeleteNestedTeamEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + DeleteNestedTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IDeleteNestedTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IDeleteNestedTeamEndpointResult.verified.cs new file mode 100644 index 000000000..8d80375cb --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IDeleteNestedTeamEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Delete a nested team relation. +/// Operation: DeleteNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IDeleteNestedTeamEndpointResult : IEndpointResponse +{ + + bool IsNoContent { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + string? NoContentContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamEndpoint.verified.cs new file mode 100644 index 000000000..6e600a3c0 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Get a nested team by nested team relation id. +/// Operation: GetNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetNestedTeamEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetNestedTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamEndpointResult.verified.cs new file mode 100644 index 000000000..e98aa022d --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Get a nested team by nested team relation id. +/// Operation: GetNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetNestedTeamEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + NestedTeam OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamsEndpoint.verified.cs new file mode 100644 index 000000000..14f4f5c19 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamsEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve a list of nested team relations. +/// Operation: GetNestedTeams. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetNestedTeamsEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetNestedTeamsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamsEndpointResult.verified.cs new file mode 100644 index 000000000..7cabd90ee --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IGetNestedTeamsEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve a list of nested team relations. +/// Operation: GetNestedTeams. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetNestedTeamsEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + MontaPageNestedTeamDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IInviteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IInviteEndpoint.verified.cs new file mode 100644 index 000000000..410d02696 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IInviteEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Nested team invite. +/// Operation: Invite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IInviteEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + InviteParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IInviteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IInviteEndpointResult.verified.cs new file mode 100644 index 000000000..42001b9d2 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IInviteEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Nested team invite. +/// Operation: Invite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IInviteEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + NestedTeam OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IRejectInviteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IRejectInviteEndpoint.verified.cs new file mode 100644 index 000000000..ca85e001c --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IRejectInviteEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Reject a nested team invitation. +/// Operation: RejectInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IRejectInviteEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + RejectInviteParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IRejectInviteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IRejectInviteEndpointResult.verified.cs new file mode 100644 index 000000000..df799c71f --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IRejectInviteEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Reject a nested team invitation. +/// Operation: RejectInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IRejectInviteEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + NestedTeam OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IUpdateNestedTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IUpdateNestedTeamEndpoint.verified.cs new file mode 100644 index 000000000..c3d1c2839 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IUpdateNestedTeamEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Update a nested team relation. +/// Operation: UpdateNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IUpdateNestedTeamEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + UpdateNestedTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IUpdateNestedTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IUpdateNestedTeamEndpointResult.verified.cs new file mode 100644 index 000000000..ddc9ce641 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/Interfaces/IUpdateNestedTeamEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Update a nested team relation. +/// Operation: UpdateNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IUpdateNestedTeamEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + NestedTeam OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PatchTransactionEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/InviteEndpoint.verified.cs similarity index 70% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PatchTransactionEndpoint.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/InviteEndpoint.verified.cs index b60aed2a4..faf81c3aa 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PatchTransactionEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/InviteEndpoint.verified.cs @@ -4,20 +4,20 @@ // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. //------------------------------------------------------------------------------ -namespace Monta.ApiClient.Generated.Endpoints.WalletTransactions; +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; /// /// Client Endpoint. -/// Description: Patch an existing transaction. -/// Operation: PatchTransaction. +/// Description: Nested team invite. +/// Operation: Invite. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public class PatchTransactionEndpoint : IPatchTransactionEndpoint +public class InviteEndpoint : IInviteEndpoint { private readonly IHttpClientFactory factory; private readonly IHttpMessageFactory httpMessageFactory; - public PatchTransactionEndpoint( + public InviteEndpoint( IHttpClientFactory factory, IHttpMessageFactory httpMessageFactory) { @@ -25,25 +25,25 @@ public PatchTransactionEndpoint( this.httpMessageFactory = httpMessageFactory; } - public async Task ExecuteAsync( - PatchTransactionParameters parameters, + public async Task ExecuteAsync( + InviteParameters parameters, string httpClientName = "Monta-ApiClient", CancellationToken cancellationToken = default) { var client = factory.CreateClient(httpClientName); - var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/wallet-transactions/{transactionId}"); - requestBuilder.WithPathParameter("transactionId", parameters.TransactionId); + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/nested-teams/invite"); requestBuilder.WithBody(parameters.Request); - using var requestMessage = requestBuilder.Build(HttpMethod.Patch); + using var requestMessage = requestBuilder.Build(HttpMethod.Post); using var response = await client.SendAsync(requestMessage, cancellationToken); var responseBuilder = httpMessageFactory.FromResponse(response); - responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); - return await responseBuilder.BuildResponseAsync(x => new PatchTransactionEndpointResult(x), cancellationToken); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new InviteEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/InviteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/InviteEndpointResult.verified.cs new file mode 100644 index 000000000..48780f8e6 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/InviteEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint result. +/// Description: Nested team invite. +/// Operation: Invite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class InviteEndpointResult : EndpointResponse, IInviteEndpointResult +{ + public InviteEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public NestedTeam OkContent + => IsOk && ContentObject is NestedTeam result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/RejectInviteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/RejectInviteEndpoint.verified.cs new file mode 100644 index 000000000..17ee681d5 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/RejectInviteEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint. +/// Description: Reject a nested team invitation. +/// Operation: RejectInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class RejectInviteEndpoint : IRejectInviteEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public RejectInviteEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + RejectInviteParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/nested-teams/{relationId}/reject-invite"); + requestBuilder.WithPathParameter("relationId", parameters.RelationId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Post); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new RejectInviteEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/RejectInviteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/RejectInviteEndpointResult.verified.cs new file mode 100644 index 000000000..83ea12619 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/RejectInviteEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint result. +/// Description: Reject a nested team invitation. +/// Operation: RejectInvite. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class RejectInviteEndpointResult : EndpointResponse, IRejectInviteEndpointResult +{ + public RejectInviteEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public NestedTeam OkContent + => IsOk && ContentObject is NestedTeam result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/UpdateNestedTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/UpdateNestedTeamEndpoint.verified.cs new file mode 100644 index 000000000..e3412611a --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/UpdateNestedTeamEndpoint.verified.cs @@ -0,0 +1,50 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint. +/// Description: Update a nested team relation. +/// Operation: UpdateNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UpdateNestedTeamEndpoint : IUpdateNestedTeamEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public UpdateNestedTeamEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + UpdateNestedTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/nested-teams/{relationId}"); + requestBuilder.WithPathParameter("relationId", parameters.RelationId); + requestBuilder.WithBody(parameters.Request); + + using var requestMessage = requestBuilder.Build(HttpMethod.Patch); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new UpdateNestedTeamEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/UpdateNestedTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/UpdateNestedTeamEndpointResult.verified.cs new file mode 100644 index 000000000..484e3a6de --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/NestedTeams/UpdateNestedTeamEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.NestedTeams; + +/// +/// Client Endpoint result. +/// Description: Update a nested team relation. +/// Operation: UpdateNestedTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UpdateNestedTeamEndpointResult : EndpointResponse, IUpdateNestedTeamEndpointResult +{ + public UpdateNestedTeamEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public NestedTeam OkContent + => IsOk && ContentObject is NestedTeam result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorEndpoint.verified.cs index ead8d5259..09a315354 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetOperatorEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorEndpointResult.verified.cs index b8f8f06e9..d9d2dd9d9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Operator OkContent => IsOk && ContentObject is Operator result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorsEndpoint.verified.cs index 9b4ef98ea..b23935f98 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorsEndpoint.verified.cs @@ -43,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetOperatorsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorsEndpointResult.verified.cs index 56414a786..511582d48 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/GetOperatorsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageOperatorDto OkContent => IsOk && ContentObject is MontaPageOperatorDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/Interfaces/IGetOperatorEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/Interfaces/IGetOperatorEndpointResult.verified.cs index c6f5f145f..392baf3f0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/Interfaces/IGetOperatorEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/Interfaces/IGetOperatorEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IGetOperatorEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + Operator OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IGetOperatorEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/Interfaces/IGetOperatorsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/Interfaces/IGetOperatorsEndpointResult.verified.cs index 9854f617d..85188265a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/Interfaces/IGetOperatorsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Operators/Interfaces/IGetOperatorsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetOperatorsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageOperatorDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/GetPaymentTerminalsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/GetPaymentTerminalsEndpoint.verified.cs index 77325e70d..82fd08727 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/GetPaymentTerminalsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/GetPaymentTerminalsEndpoint.verified.cs @@ -46,6 +46,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetPaymentTerminalsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/GetPaymentTerminalsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/GetPaymentTerminalsEndpointResult.verified.cs index 07de1fe8d..4407bf415 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/GetPaymentTerminalsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/GetPaymentTerminalsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPagePaymentTerminalDto OkContent => IsOk && ContentObject is MontaPagePaymentTerminalDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/Interfaces/IGetPaymentTerminalsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/Interfaces/IGetPaymentTerminalsEndpointResult.verified.cs index e79bc3fff..f9047291b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/Interfaces/IGetPaymentTerminalsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PaymentTerminals/Interfaces/IGetPaymentTerminalsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetPaymentTerminalsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPagePaymentTerminalDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlanEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlanEndpoint.verified.cs index 10a4d7209..ea2ae382f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlanEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlanEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetPlanEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlanEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlanEndpointResult.verified.cs index 8a88221d7..02062e591 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlanEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlanEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Plan OkContent => IsOk && ContentObject is Plan result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlansEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlansEndpoint.verified.cs index 2c136ce21..ba47851d8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlansEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlansEndpoint.verified.cs @@ -43,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetPlansEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlansEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlansEndpointResult.verified.cs index c45923cc2..e32ef362d 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlansEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/GetPlansEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPagePlanDto OkContent => IsOk && ContentObject is MontaPagePlanDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/Interfaces/IGetPlanEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/Interfaces/IGetPlanEndpointResult.verified.cs index e53ad632c..7daac7238 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/Interfaces/IGetPlanEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/Interfaces/IGetPlanEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetPlanEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + Plan OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/Interfaces/IGetPlansEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/Interfaces/IGetPlansEndpointResult.verified.cs index 6969c1dcb..89db2fabe 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/Interfaces/IGetPlansEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Plans/Interfaces/IGetPlansEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetPlansEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPagePlanDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/GetPriceGroupTagsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/GetPriceGroupTagsEndpoint.verified.cs index 47baaab49..264a0be30 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/GetPriceGroupTagsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/GetPriceGroupTagsEndpoint.verified.cs @@ -43,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetPriceGroupTagsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/GetPriceGroupTagsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/GetPriceGroupTagsEndpointResult.verified.cs index 0eed502f8..32e2ab250 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/GetPriceGroupTagsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/GetPriceGroupTagsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPagePriceGroupTagDto OkContent => IsOk && ContentObject is MontaPagePriceGroupTagDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/Interfaces/IGetPriceGroupTagsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/Interfaces/IGetPriceGroupTagsEndpointResult.verified.cs index d98f619fd..da8b9836a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/Interfaces/IGetPriceGroupTagsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroupTags/Interfaces/IGetPriceGroupTagsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetPriceGroupTagsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPagePriceGroupTagDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/ApplyPriceGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/ApplyPriceGroupEndpoint.verified.cs index ea5847f05..d6cc79eb2 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/ApplyPriceGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/ApplyPriceGroupEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new ApplyPriceGroupEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/ApplyPriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/ApplyPriceGroupEndpointResult.verified.cs index bcbf6dcd3..84df6ba5e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/ApplyPriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/ApplyPriceGroupEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/CreatePriceGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/CreatePriceGroupEndpoint.verified.cs index 23a4084ec..4ea519eb9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/CreatePriceGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/CreatePriceGroupEndpoint.verified.cs @@ -42,6 +42,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.Created); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new CreatePriceGroupEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/CreatePriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/CreatePriceGroupEndpointResult.verified.cs index 1ffe4eeb1..0c889b01b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/CreatePriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/CreatePriceGroupEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/DeletePriceGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/DeletePriceGroupEndpoint.verified.cs index b8f7e222a..574b752ce 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/DeletePriceGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/DeletePriceGroupEndpoint.verified.cs @@ -42,6 +42,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeletePriceGroupEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/DeletePriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/DeletePriceGroupEndpointResult.verified.cs index 799a67ca1..29324d30f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/DeletePriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/DeletePriceGroupEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupEndpoint.verified.cs index 38ca297d6..708deaa9f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetPriceGroupEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupEndpointResult.verified.cs index 938eaeb83..40946465e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public PriceGroup OkContent => IsOk && ContentObject is PriceGroup result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupsEndpoint.verified.cs index 56b6f7565..b0db6b669 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupsEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetPriceGroupsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupsEndpointResult.verified.cs index 256587b12..ec835d861 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/GetPriceGroupsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPagePriceGroupDto OkContent => IsOk && ContentObject is MontaPagePriceGroupDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IApplyPriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IApplyPriceGroupEndpointResult.verified.cs index 601475b20..6be9edb9b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IApplyPriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IApplyPriceGroupEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IApplyPriceGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } PriceGroup OkContent { get; } @@ -29,5 +31,7 @@ public interface IApplyPriceGroupEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/ICreatePriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/ICreatePriceGroupEndpointResult.verified.cs index da9edec9b..746a3cef3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/ICreatePriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/ICreatePriceGroupEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface ICreatePriceGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } string? CreatedContent { get; } @@ -29,5 +31,7 @@ public interface ICreatePriceGroupEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IDeletePriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IDeletePriceGroupEndpointResult.verified.cs index 0c03674d9..f1abe0cfe 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IDeletePriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IDeletePriceGroupEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IDeletePriceGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } string? NoContentContent { get; } @@ -29,5 +31,7 @@ public interface IDeletePriceGroupEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IGetPriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IGetPriceGroupEndpointResult.verified.cs index 04b2948a5..6ce946a67 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IGetPriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IGetPriceGroupEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetPriceGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + PriceGroup OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IGetPriceGroupsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IGetPriceGroupsEndpointResult.verified.cs index cfe085171..0758caa34 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IGetPriceGroupsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IGetPriceGroupsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetPriceGroupsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPagePriceGroupDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/ISetDefaultPriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/ISetDefaultPriceGroupEndpointResult.verified.cs index caa9985e4..b7dfac308 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/ISetDefaultPriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/ISetDefaultPriceGroupEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface ISetDefaultPriceGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } PriceGroup OkContent { get; } @@ -29,5 +31,7 @@ public interface ISetDefaultPriceGroupEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IUpdatePriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IUpdatePriceGroupEndpointResult.verified.cs index 2c032aad9..bce5bb048 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IUpdatePriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/Interfaces/IUpdatePriceGroupEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IUpdatePriceGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } PriceGroup OkContent { get; } @@ -29,5 +31,7 @@ public interface IUpdatePriceGroupEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/SetDefaultPriceGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/SetDefaultPriceGroupEndpoint.verified.cs index 134479035..0ad4a7c68 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/SetDefaultPriceGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/SetDefaultPriceGroupEndpoint.verified.cs @@ -42,6 +42,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new SetDefaultPriceGroupEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/SetDefaultPriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/SetDefaultPriceGroupEndpointResult.verified.cs index d12b80470..4127b5a9a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/SetDefaultPriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/SetDefaultPriceGroupEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/UpdatePriceGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/UpdatePriceGroupEndpoint.verified.cs index 678d41b80..127ed689c 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/UpdatePriceGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/UpdatePriceGroupEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new UpdatePriceGroupEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/UpdatePriceGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/UpdatePriceGroupEndpointResult.verified.cs index c0db5a88e..c60a33630 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/UpdatePriceGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/PriceGroups/UpdatePriceGroupEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/GetPricesForecastEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/GetPricesForecastEndpoint.verified.cs index ce1cb9960..e5e681f45 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/GetPricesForecastEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/GetPricesForecastEndpoint.verified.cs @@ -44,6 +44,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetPricesForecastEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/GetPricesForecastEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/GetPricesForecastEndpointResult.verified.cs index b1c3d1b33..2d8e042a0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/GetPricesForecastEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/GetPricesForecastEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public PricesForecast OkContent => IsOk && ContentObject is PricesForecast result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/Interfaces/IGetPricesForecastEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/Interfaces/IGetPricesForecastEndpointResult.verified.cs index 225ecd91d..b17142e36 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/Interfaces/IGetPricesForecastEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Prices/Interfaces/IGetPricesForecastEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetPricesForecastEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + PricesForecast OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportEndpoint.verified.cs new file mode 100644 index 000000000..9d0caed20 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Reports; + +/// +/// Client Endpoint. +/// Description: Retrieve a report related to a charge point. +/// Operation: GetReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetReportEndpoint : IGetReportEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetReportEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetReportParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/reports/{reportId}"); + requestBuilder.WithPathParameter("reportId", parameters.ReportId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetReportEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportEndpointResult.verified.cs new file mode 100644 index 000000000..0c426b8bd --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Reports; + +/// +/// Client Endpoint result. +/// Description: Retrieve a report related to a charge point. +/// Operation: GetReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetReportEndpointResult : EndpointResponse, IGetReportEndpointResult +{ + public GetReportEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public ReportDto OkContent + => IsOk && ContentObject is ReportDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportsEndpoint.verified.cs new file mode 100644 index 000000000..9dd56eed4 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportsEndpoint.verified.cs @@ -0,0 +1,55 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Reports; + +/// +/// Client Endpoint. +/// Description: Retrieve a list of reports for charge point(s). +/// Operation: GetReports. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetReportsEndpoint : IGetReportsEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetReportsEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetReportsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/reports"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithQueryParameter("chargePointId", parameters.ChargePointId); + requestBuilder.WithQueryParameter("state", parameters.State); + requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); + requestBuilder.WithQueryParameter("toDate", parameters.ToDate); + requestBuilder.WithQueryParameter("priority", parameters.Priority); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetReportsEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportsEndpointResult.verified.cs new file mode 100644 index 000000000..821484be8 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/GetReportsEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Reports; + +/// +/// Client Endpoint result. +/// Description: Retrieve a list of reports for charge point(s). +/// Operation: GetReports. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetReportsEndpointResult : EndpointResponse, IGetReportsEndpointResult +{ + public GetReportsEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageReportDto OkContent + => IsOk && ContentObject is MontaPageReportDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportEndpoint.verified.cs new file mode 100644 index 000000000..1aaba0f90 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Reports.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve a report related to a charge point. +/// Operation: GetReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetReportEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetReportParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportEndpointResult.verified.cs new file mode 100644 index 000000000..925114b00 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Reports.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve a report related to a charge point. +/// Operation: GetReport. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetReportEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + ReportDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportsEndpoint.verified.cs new file mode 100644 index 000000000..60489b6ab --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportsEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Reports.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve a list of reports for charge point(s). +/// Operation: GetReports. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetReportsEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetReportsParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportsEndpointResult.verified.cs new file mode 100644 index 000000000..3e84c3ce8 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Reports/Interfaces/IGetReportsEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Reports.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve a list of reports for charge point(s). +/// Operation: GetReports. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetReportsEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + MontaPageReportDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/DeleteSiteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/DeleteSiteEndpoint.verified.cs index 45ce4d493..2d12e0d37 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/DeleteSiteEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/DeleteSiteEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteSiteEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/DeleteSiteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/DeleteSiteEndpointResult.verified.cs index 4cf4b47da..63fd829c3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/DeleteSiteEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/DeleteSiteEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/GetSitesEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/GetSitesEndpoint.verified.cs index 6b383925c..4b3fa082b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/GetSitesEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/GetSitesEndpoint.verified.cs @@ -38,6 +38,8 @@ public async Task ExecuteAsync( requestBuilder.WithQueryParameter("teamId", parameters.TeamId); requestBuilder.WithQueryParameter("partnerExternalId", parameters.PartnerExternalId); requestBuilder.WithQueryParameter("sortByLocation", parameters.SortByLocation); + requestBuilder.WithQueryParameter("operatorId", parameters.OperatorId); + requestBuilder.WithQueryParameter("includePublic", parameters.IncludePublic); requestBuilder.WithQueryParameter("includeDeleted", parameters.IncludeDeleted); using var requestMessage = requestBuilder.Build(HttpMethod.Get); @@ -47,6 +49,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetSitesEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/GetSitesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/GetSitesEndpointResult.verified.cs index 441835cc4..0a8b56dda 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/GetSitesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/GetSitesEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageSiteDto OkContent => IsOk && ContentObject is MontaPageSiteDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IDeleteSiteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IDeleteSiteEndpointResult.verified.cs index 4199deef5..42a39e74e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IDeleteSiteEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IDeleteSiteEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IDeleteSiteEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IDeleteSiteEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IGetSitesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IGetSitesEndpointResult.verified.cs index 8d194c420..fd361758d 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IGetSitesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IGetSitesEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetSitesEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageSiteDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IPatchSiteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IPatchSiteEndpointResult.verified.cs index c8412b9ea..700e9d9b3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IPatchSiteEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IPatchSiteEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPatchSiteEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + Site OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPatchSiteEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IPostSiteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IPostSiteEndpointResult.verified.cs index f2723e3ee..050532739 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IPostSiteEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/Interfaces/IPostSiteEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPostSiteEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPostSiteEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PatchSiteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PatchSiteEndpoint.verified.cs index 7203f08d1..d481f9cf3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PatchSiteEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PatchSiteEndpoint.verified.cs @@ -44,6 +44,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PatchSiteEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PatchSiteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PatchSiteEndpointResult.verified.cs index 947c939f5..edeacdcaf 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PatchSiteEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PatchSiteEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Site OkContent => IsOk && ContentObject is Site result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PostSiteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PostSiteEndpoint.verified.cs index 5b384c2cc..e92cafd92 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PostSiteEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PostSiteEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PostSiteEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PostSiteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PostSiteEndpointResult.verified.cs index 99a067214..1caa9edb3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PostSiteEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Sites/PostSiteEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/DeleteSponsoredChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/DeleteSponsoredChargePointEndpoint.verified.cs index 7f841d9e7..a0013adaa 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/DeleteSponsoredChargePointEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/DeleteSponsoredChargePointEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteSponsoredChargePointEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/DeleteSponsoredChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/DeleteSponsoredChargePointEndpointResult.verified.cs index 973ea3fec..bb1f3a081 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/DeleteSponsoredChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/DeleteSponsoredChargePointEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/GetSponsoredChargePointsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/GetSponsoredChargePointsEndpoint.verified.cs index fdcdd1af7..6ecd1f6c1 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/GetSponsoredChargePointsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/GetSponsoredChargePointsEndpoint.verified.cs @@ -46,6 +46,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetSponsoredChargePointsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/GetSponsoredChargePointsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/GetSponsoredChargePointsEndpointResult.verified.cs index 5ffc5f159..eaef8a2a5 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/GetSponsoredChargePointsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/GetSponsoredChargePointsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageSponsoredChargePointDto OkContent => IsOk && ContentObject is MontaPageSponsoredChargePointDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IDeleteSponsoredChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IDeleteSponsoredChargePointEndpointResult.verified.cs index d2c8bc16d..bd100f140 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IDeleteSponsoredChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IDeleteSponsoredChargePointEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IDeleteSponsoredChargePointEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IDeleteSponsoredChargePointEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IGetSponsoredChargePointsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IGetSponsoredChargePointsEndpointResult.verified.cs index 6185a3ac5..3b180dec9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IGetSponsoredChargePointsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IGetSponsoredChargePointsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetSponsoredChargePointsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageSponsoredChargePointDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IPatchSponsoredChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IPatchSponsoredChargePointEndpointResult.verified.cs index acc48c2a8..b8c54037e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IPatchSponsoredChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IPatchSponsoredChargePointEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IPatchSponsoredChargePointEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + SponsoredChargePoint OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IPostSponsoredChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IPostSponsoredChargePointEndpointResult.verified.cs index 070d5b1b5..36011ee3a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IPostSponsoredChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/Interfaces/IPostSponsoredChargePointEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPostSponsoredChargePointEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPostSponsoredChargePointEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PatchSponsoredChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PatchSponsoredChargePointEndpoint.verified.cs index 696427eff..052a74c60 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PatchSponsoredChargePointEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PatchSponsoredChargePointEndpoint.verified.cs @@ -43,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PatchSponsoredChargePointEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PatchSponsoredChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PatchSponsoredChargePointEndpointResult.verified.cs index ec3eb628d..eb11a1b63 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PatchSponsoredChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PatchSponsoredChargePointEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public SponsoredChargePoint OkContent => IsOk && ContentObject is SponsoredChargePoint result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PostSponsoredChargePointEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PostSponsoredChargePointEndpoint.verified.cs index 8109d4244..21b599acf 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PostSponsoredChargePointEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PostSponsoredChargePointEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PostSponsoredChargePointEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PostSponsoredChargePointEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PostSponsoredChargePointEndpointResult.verified.cs index 42af63aa3..5e91b92da 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PostSponsoredChargePointEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SponsoredChargePoints/PostSponsoredChargePointEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchaseEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchaseEndpoint.verified.cs index 9d2198d65..d27d03817 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchaseEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchaseEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetSubscriptionPurchaseEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchaseEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchaseEndpointResult.verified.cs index b568ea4ec..8ba00c22b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchaseEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchaseEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public SubscriptionPurchase OkContent => IsOk && ContentObject is SubscriptionPurchase result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchasesEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchasesEndpoint.verified.cs index 536c84575..400c83dd6 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchasesEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchasesEndpoint.verified.cs @@ -45,6 +45,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetSubscriptionPurchasesEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchasesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchasesEndpointResult.verified.cs index 861b52b81..627e65c71 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchasesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/GetSubscriptionPurchasesEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageSubscriptionPurchaseDto OkContent => IsOk && ContentObject is MontaPageSubscriptionPurchaseDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/Interfaces/IGetSubscriptionPurchaseEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/Interfaces/IGetSubscriptionPurchaseEndpointResult.verified.cs index c4fd03544..f40c8fd89 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/Interfaces/IGetSubscriptionPurchaseEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/Interfaces/IGetSubscriptionPurchaseEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetSubscriptionPurchaseEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + SubscriptionPurchase OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/Interfaces/IGetSubscriptionPurchasesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/Interfaces/IGetSubscriptionPurchasesEndpointResult.verified.cs index 09bfb3c55..71ac925d0 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/Interfaces/IGetSubscriptionPurchasesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/SubscriptionPurchases/Interfaces/IGetSubscriptionPurchasesEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetSubscriptionPurchasesEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageSubscriptionPurchaseDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/ApproveSubscriptionEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/ApproveSubscriptionEndpoint.verified.cs index 90b4ee1b1..c37739faa 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/ApproveSubscriptionEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/ApproveSubscriptionEndpoint.verified.cs @@ -43,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new ApproveSubscriptionEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/ApproveSubscriptionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/ApproveSubscriptionEndpointResult.verified.cs index de1cefe53..f8c900063 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/ApproveSubscriptionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/ApproveSubscriptionEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Subscription OkContent => IsOk && ContentObject is Subscription result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/CreateSubscriptionEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/CreateSubscriptionEndpoint.verified.cs index 08a4612e9..38c2eb533 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/CreateSubscriptionEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/CreateSubscriptionEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.Created); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new CreateSubscriptionEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/CreateSubscriptionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/CreateSubscriptionEndpointResult.verified.cs index 4eb725eec..7dc2d5b45 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/CreateSubscriptionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/CreateSubscriptionEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/DeleteSubscriptionEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/DeleteSubscriptionEndpoint.verified.cs index 3cc6ccfdf..e8ab8cbcb 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/DeleteSubscriptionEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/DeleteSubscriptionEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteSubscriptionEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/DeleteSubscriptionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/DeleteSubscriptionEndpointResult.verified.cs index d1b5c59c6..1be6e12d5 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/DeleteSubscriptionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/DeleteSubscriptionEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionEndpoint.verified.cs index 22b238f71..a74bf0df4 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetSubscriptionEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionEndpointResult.verified.cs index 89c515137..44966b1d1 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Subscription OkContent => IsOk && ContentObject is Subscription result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionsEndpoint.verified.cs index f32ed0418..bc5ac1215 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionsEndpoint.verified.cs @@ -37,6 +37,8 @@ public async Task ExecuteAsync( requestBuilder.WithQueryParameter("perPage", parameters.PerPage); requestBuilder.WithQueryParameter("planId", parameters.PlanId); requestBuilder.WithQueryParameter("chargePointId", parameters.ChargePointId); + requestBuilder.WithQueryParameter("customerId", parameters.CustomerId); + requestBuilder.WithQueryParameter("customerType", parameters.CustomerType); requestBuilder.WithQueryParameter("subscriptionPurchaseId", parameters.SubscriptionPurchaseId); using var requestMessage = requestBuilder.Build(HttpMethod.Get); @@ -46,6 +48,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetSubscriptionsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionsEndpointResult.verified.cs index 0b92c60d4..31da1a32c 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/GetSubscriptionsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageSubscriptionDto OkContent => IsOk && ContentObject is MontaPageSubscriptionDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IApproveSubscriptionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IApproveSubscriptionEndpointResult.verified.cs index 3e60bc6b8..86f9309e5 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IApproveSubscriptionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IApproveSubscriptionEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IApproveSubscriptionEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + Subscription OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/ICreateSubscriptionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/ICreateSubscriptionEndpointResult.verified.cs index ede45581f..062d4ca47 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/ICreateSubscriptionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/ICreateSubscriptionEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface ICreateSubscriptionEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IDeleteSubscriptionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IDeleteSubscriptionEndpointResult.verified.cs index 98a16a297..3c61feadf 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IDeleteSubscriptionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IDeleteSubscriptionEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IDeleteSubscriptionEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IGetSubscriptionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IGetSubscriptionEndpointResult.verified.cs index 123926c19..46149a389 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IGetSubscriptionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IGetSubscriptionEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetSubscriptionEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + Subscription OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IGetSubscriptionsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IGetSubscriptionsEndpointResult.verified.cs index 3d38d3e5e..3504899b8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IGetSubscriptionsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Subscriptions/Interfaces/IGetSubscriptionsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetSubscriptionsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageSubscriptionDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/CreateTariffPeriodGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/CreateTariffPeriodGroupEndpoint.verified.cs index 6fd5e4e76..1c9467255 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/CreateTariffPeriodGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/CreateTariffPeriodGroupEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.Created); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new CreateTariffPeriodGroupEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/CreateTariffPeriodGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/CreateTariffPeriodGroupEndpointResult.verified.cs index a70abee56..cac086e36 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/CreateTariffPeriodGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/CreateTariffPeriodGroupEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/DeleteTariffPeriodGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/DeleteTariffPeriodGroupEndpoint.verified.cs index 7a15a9d1f..71247477f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/DeleteTariffPeriodGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/DeleteTariffPeriodGroupEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteTariffPeriodGroupEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/DeleteTariffPeriodGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/DeleteTariffPeriodGroupEndpointResult.verified.cs index ddff9a18f..117db80b3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/DeleteTariffPeriodGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/DeleteTariffPeriodGroupEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/ICreateTariffPeriodGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/ICreateTariffPeriodGroupEndpointResult.verified.cs index 4c30aeaba..84116fbef 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/ICreateTariffPeriodGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/ICreateTariffPeriodGroupEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface ICreateTariffPeriodGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/IDeleteTariffPeriodGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/IDeleteTariffPeriodGroupEndpointResult.verified.cs index 9f5319381..14ea6783a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/IDeleteTariffPeriodGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/IDeleteTariffPeriodGroupEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IDeleteTariffPeriodGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/IUpdateTariffPeriodGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/IUpdateTariffPeriodGroupEndpointResult.verified.cs index 42bd83c08..12d094849 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/IUpdateTariffPeriodGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/Interfaces/IUpdateTariffPeriodGroupEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IUpdateTariffPeriodGroupEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + TariffPeriodGroup OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/UpdateTariffPeriodGroupEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/UpdateTariffPeriodGroupEndpoint.verified.cs index 641e1a695..9dfef9dbe 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/UpdateTariffPeriodGroupEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/UpdateTariffPeriodGroupEndpoint.verified.cs @@ -43,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new UpdateTariffPeriodGroupEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/UpdateTariffPeriodGroupEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/UpdateTariffPeriodGroupEndpointResult.verified.cs index c65a0d24e..d7c6125ac 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/UpdateTariffPeriodGroupEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffPeriodGroups/UpdateTariffPeriodGroupEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public TariffPeriodGroup OkContent => IsOk && ContentObject is TariffPeriodGroup result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/CreateTariffRecurringPeriodsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/CreateTariffRecurringPeriodsEndpoint.verified.cs index b4d19da15..85cffc49f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/CreateTariffRecurringPeriodsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/CreateTariffRecurringPeriodsEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.Created); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new CreateTariffRecurringPeriodsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/CreateTariffRecurringPeriodsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/CreateTariffRecurringPeriodsEndpointResult.verified.cs index d0926c48c..45fa6bc39 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/CreateTariffRecurringPeriodsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/CreateTariffRecurringPeriodsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/DeleteTariffRecurringPeriodEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/DeleteTariffRecurringPeriodEndpoint.verified.cs index 15be639d7..387ee7318 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/DeleteTariffRecurringPeriodEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/DeleteTariffRecurringPeriodEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteTariffRecurringPeriodEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/DeleteTariffRecurringPeriodEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/DeleteTariffRecurringPeriodEndpointResult.verified.cs index 8c090c327..dafdbac38 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/DeleteTariffRecurringPeriodEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/DeleteTariffRecurringPeriodEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodEndpoint.verified.cs index b30a65ab2..9eeae5911 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodEndpoint.verified.cs @@ -42,6 +42,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetTariffRecurringPeriodEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodEndpointResult.verified.cs index b72e85cb7..4052350cf 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodsEndpoint.verified.cs index e07a10678..ec0398e7b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodsEndpoint.verified.cs @@ -45,6 +45,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetTariffRecurringPeriodsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodsEndpointResult.verified.cs index 0977bfb98..040f5d6ec 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/GetTariffRecurringPeriodsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public PageTariffRecurringPeriodDto OkContent => IsOk && ContentObject is PageTariffRecurringPeriodDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/ICreateTariffRecurringPeriodsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/ICreateTariffRecurringPeriodsEndpointResult.verified.cs index 184875c28..7b2cd34bf 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/ICreateTariffRecurringPeriodsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/ICreateTariffRecurringPeriodsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface ICreateTariffRecurringPeriodsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IDeleteTariffRecurringPeriodEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IDeleteTariffRecurringPeriodEndpointResult.verified.cs index 4e2e2cc74..325d29f04 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IDeleteTariffRecurringPeriodEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IDeleteTariffRecurringPeriodEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IDeleteTariffRecurringPeriodEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IGetTariffRecurringPeriodEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IGetTariffRecurringPeriodEndpointResult.verified.cs index 86f2dd5be..853180d7e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IGetTariffRecurringPeriodEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IGetTariffRecurringPeriodEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IGetTariffRecurringPeriodEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } TariffRecurringPeriod OkContent { get; } @@ -29,5 +31,7 @@ public interface IGetTariffRecurringPeriodEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IGetTariffRecurringPeriodsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IGetTariffRecurringPeriodsEndpointResult.verified.cs index 087e1cdd2..f6cc0fd3b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IGetTariffRecurringPeriodsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IGetTariffRecurringPeriodsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetTariffRecurringPeriodsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + PageTariffRecurringPeriodDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IUpdateTariffRecurringPeriodsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IUpdateTariffRecurringPeriodsEndpointResult.verified.cs index 310c5b0f1..e2eec3f9e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IUpdateTariffRecurringPeriodsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/Interfaces/IUpdateTariffRecurringPeriodsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IUpdateTariffRecurringPeriodsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + TariffRecurringPeriod OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/UpdateTariffRecurringPeriodsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/UpdateTariffRecurringPeriodsEndpoint.verified.cs index 3f410af18..7824cd981 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/UpdateTariffRecurringPeriodsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/UpdateTariffRecurringPeriodsEndpoint.verified.cs @@ -43,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new UpdateTariffRecurringPeriodsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/UpdateTariffRecurringPeriodsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/UpdateTariffRecurringPeriodsEndpointResult.verified.cs index 2d22eaa44..8c6959ec7 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/UpdateTariffRecurringPeriodsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TariffRecurringPeriods/UpdateTariffRecurringPeriodsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public TariffRecurringPeriod OkContent => IsOk && ContentObject is TariffRecurringPeriod result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/CreateTariffEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/CreateTariffEndpoint.verified.cs index f6f79dbe1..a75e16cf8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/CreateTariffEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/CreateTariffEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.Created); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new CreateTariffEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/CreateTariffEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/CreateTariffEndpointResult.verified.cs index cea835699..af6158208 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/CreateTariffEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/CreateTariffEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/Interfaces/ICreateTariffEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/Interfaces/ICreateTariffEndpointResult.verified.cs index 6d3c1e348..1c412aeda 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/Interfaces/ICreateTariffEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/Interfaces/ICreateTariffEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface ICreateTariffEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/Interfaces/IUpdateTariffEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/Interfaces/IUpdateTariffEndpointResult.verified.cs index 22852f6c6..c4e99149e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/Interfaces/IUpdateTariffEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/Interfaces/IUpdateTariffEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IUpdateTariffEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + TariffDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/UpdateTariffEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/UpdateTariffEndpoint.verified.cs index 7864c7ccc..a2a9c69f9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/UpdateTariffEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/UpdateTariffEndpoint.verified.cs @@ -43,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new UpdateTariffEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/UpdateTariffEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/UpdateTariffEndpointResult.verified.cs index ededc6e86..f295bc5b3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/UpdateTariffEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Tariffs/UpdateTariffEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public TariffDto OkContent => IsOk && ContentObject is TariffDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/DeleteTeamMemberProfileEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/DeleteTeamMemberProfileEndpoint.verified.cs new file mode 100644 index 000000000..e40fe2f15 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/DeleteTeamMemberProfileEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint. +/// Description: Delete an existing team member profile. +/// Operation: DeleteTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class DeleteTeamMemberProfileEndpoint : IDeleteTeamMemberProfileEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public DeleteTeamMemberProfileEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + DeleteTeamMemberProfileParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/team-member-profiles/{id}"); + requestBuilder.WithPathParameter("id", parameters.Id); + + using var requestMessage = requestBuilder.Build(HttpMethod.Delete); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new DeleteTeamMemberProfileEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/DeleteTeamMemberProfileEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/DeleteTeamMemberProfileEndpointResult.verified.cs new file mode 100644 index 000000000..68589e8e4 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/DeleteTeamMemberProfileEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint result. +/// Description: Delete an existing team member profile. +/// Operation: DeleteTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class DeleteTeamMemberProfileEndpointResult : EndpointResponse, IDeleteTeamMemberProfileEndpointResult +{ + public DeleteTeamMemberProfileEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsNoContent + => StatusCode == HttpStatusCode.NoContent; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public string? NoContentContent + => IsNoContent && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNoContent property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfileEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfileEndpoint.verified.cs new file mode 100644 index 000000000..2d84d71c1 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfileEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint. +/// Description: Retrieve a team member profile by id. +/// Operation: GetTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetTeamMemberProfileEndpoint : IGetTeamMemberProfileEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetTeamMemberProfileEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetTeamMemberProfileParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/team-member-profiles/{id}"); + requestBuilder.WithPathParameter("id", parameters.Id); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetTeamMemberProfileEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfileEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfileEndpointResult.verified.cs new file mode 100644 index 000000000..34e48dd2d --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfileEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint result. +/// Description: Retrieve a team member profile by id. +/// Operation: GetTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetTeamMemberProfileEndpointResult : EndpointResponse, IGetTeamMemberProfileEndpointResult +{ + public GetTeamMemberProfileEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public TeamMemberProfile OkContent + => IsOk && ContentObject is TeamMemberProfile result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfilesEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfilesEndpoint.verified.cs new file mode 100644 index 000000000..42ad7a739 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfilesEndpoint.verified.cs @@ -0,0 +1,52 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint. +/// Description: Retrieve a list of team member profiles. +/// Operation: GetTeamMemberProfiles. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetTeamMemberProfilesEndpoint : IGetTeamMemberProfilesEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetTeamMemberProfilesEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetTeamMemberProfilesParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/team-member-profiles"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithQueryParameter("teamId", parameters.TeamId); + requestBuilder.WithQueryParameter("name", parameters.Name); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetTeamMemberProfilesEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfilesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfilesEndpointResult.verified.cs new file mode 100644 index 000000000..83b04893f --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/GetTeamMemberProfilesEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint result. +/// Description: Retrieve a list of team member profiles. +/// Operation: GetTeamMemberProfiles. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetTeamMemberProfilesEndpointResult : EndpointResponse, IGetTeamMemberProfilesEndpointResult +{ + public GetTeamMemberProfilesEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageTeamMemberProfileDto OkContent + => IsOk && ContentObject is MontaPageTeamMemberProfileDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IDeleteTeamMemberProfileEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IDeleteTeamMemberProfileEndpoint.verified.cs new file mode 100644 index 000000000..b2da92572 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IDeleteTeamMemberProfileEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Delete an existing team member profile. +/// Operation: DeleteTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IDeleteTeamMemberProfileEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + DeleteTeamMemberProfileParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IDeleteTeamMemberProfileEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IDeleteTeamMemberProfileEndpointResult.verified.cs new file mode 100644 index 000000000..75883100a --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IDeleteTeamMemberProfileEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Delete an existing team member profile. +/// Operation: DeleteTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IDeleteTeamMemberProfileEndpointResult : IEndpointResponse +{ + + bool IsNoContent { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + string? NoContentContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfileEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfileEndpoint.verified.cs new file mode 100644 index 000000000..713ffdbd8 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfileEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve a team member profile by id. +/// Operation: GetTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetTeamMemberProfileEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetTeamMemberProfileParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfileEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfileEndpointResult.verified.cs new file mode 100644 index 000000000..b41fffc48 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfileEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve a team member profile by id. +/// Operation: GetTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetTeamMemberProfileEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + TeamMemberProfile OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfilesEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfilesEndpoint.verified.cs new file mode 100644 index 000000000..12b3f7b22 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfilesEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve a list of team member profiles. +/// Operation: GetTeamMemberProfiles. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetTeamMemberProfilesEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetTeamMemberProfilesParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfilesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfilesEndpointResult.verified.cs new file mode 100644 index 000000000..07ca2c22f --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IGetTeamMemberProfilesEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve a list of team member profiles. +/// Operation: GetTeamMemberProfiles. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetTeamMemberProfilesEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + MontaPageTeamMemberProfileDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IPostTeamMemberProfileEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IPostTeamMemberProfileEndpoint.verified.cs new file mode 100644 index 000000000..880d09701 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IPostTeamMemberProfileEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Create a team member profile. +/// Operation: PostTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IPostTeamMemberProfileEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + PostTeamMemberProfileParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IPostTeamMemberProfileEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IPostTeamMemberProfileEndpointResult.verified.cs new file mode 100644 index 000000000..38b08a2c5 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IPostTeamMemberProfileEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Create a team member profile. +/// Operation: PostTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IPostTeamMemberProfileEndpointResult : IEndpointResponse +{ + + bool IsCreated { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + string? CreatedContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IUpdateTeamMemberProfileEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IUpdateTeamMemberProfileEndpoint.verified.cs new file mode 100644 index 000000000..da3bad4e3 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IUpdateTeamMemberProfileEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Patch a team member profile. +/// Operation: UpdateTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IUpdateTeamMemberProfileEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + UpdateTeamMemberProfileParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IUpdateTeamMemberProfileEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IUpdateTeamMemberProfileEndpointResult.verified.cs new file mode 100644 index 000000000..f16d86935 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/Interfaces/IUpdateTeamMemberProfileEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Patch a team member profile. +/// Operation: UpdateTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IUpdateTeamMemberProfileEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + TeamMemberProfile OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/PostTeamMemberProfileEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/PostTeamMemberProfileEndpoint.verified.cs new file mode 100644 index 000000000..a61b14297 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/PostTeamMemberProfileEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint. +/// Description: Create a team member profile. +/// Operation: PostTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PostTeamMemberProfileEndpoint : IPostTeamMemberProfileEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public PostTeamMemberProfileEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + PostTeamMemberProfileParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/team-member-profiles"); + requestBuilder.WithBody(parameters.Request); + + using var requestMessage = requestBuilder.Build(HttpMethod.Post); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddErrorResponse(HttpStatusCode.Created); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new PostTeamMemberProfileEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/PostTeamMemberProfileEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/PostTeamMemberProfileEndpointResult.verified.cs new file mode 100644 index 000000000..91b106275 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/PostTeamMemberProfileEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint result. +/// Description: Create a team member profile. +/// Operation: PostTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class PostTeamMemberProfileEndpointResult : EndpointResponse, IPostTeamMemberProfileEndpointResult +{ + public PostTeamMemberProfileEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsCreated + => StatusCode == HttpStatusCode.Created; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public string? CreatedContent + => IsCreated && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsCreated property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/UpdateTeamMemberProfileEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/UpdateTeamMemberProfileEndpoint.verified.cs new file mode 100644 index 000000000..219e95dcd --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/UpdateTeamMemberProfileEndpoint.verified.cs @@ -0,0 +1,50 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint. +/// Description: Patch a team member profile. +/// Operation: UpdateTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UpdateTeamMemberProfileEndpoint : IUpdateTeamMemberProfileEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public UpdateTeamMemberProfileEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + UpdateTeamMemberProfileParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/team-member-profiles/{id}"); + requestBuilder.WithPathParameter("id", parameters.Id); + requestBuilder.WithBody(parameters.Request); + + using var requestMessage = requestBuilder.Build(HttpMethod.Patch); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new UpdateTeamMemberProfileEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/UpdateTeamMemberProfileEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/UpdateTeamMemberProfileEndpointResult.verified.cs new file mode 100644 index 000000000..dd4fc1ecc --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMemberProfiles/UpdateTeamMemberProfileEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles; + +/// +/// Client Endpoint result. +/// Description: Patch a team member profile. +/// Operation: UpdateTeamMemberProfile. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UpdateTeamMemberProfileEndpointResult : EndpointResponse, IUpdateTeamMemberProfileEndpointResult +{ + public UpdateTeamMemberProfileEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public TeamMemberProfile OkContent + => IsOk && ContentObject is TeamMemberProfile result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/AcceptTeamMemberJoinRequestEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/AcceptTeamMemberJoinRequestEndpoint.verified.cs new file mode 100644 index 000000000..a6a31ff55 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/AcceptTeamMemberJoinRequestEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMembers; + +/// +/// Client Endpoint. +/// Description: Approve a team member who requested to join a team. +/// Operation: AcceptTeamMemberJoinRequest. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class AcceptTeamMemberJoinRequestEndpoint : IAcceptTeamMemberJoinRequestEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public AcceptTeamMemberJoinRequestEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + AcceptTeamMemberJoinRequestParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/team-members/{id}/accept"); + requestBuilder.WithPathParameter("id", parameters.Id); + + using var requestMessage = requestBuilder.Build(HttpMethod.Post); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new AcceptTeamMemberJoinRequestEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/AcceptTeamMemberJoinRequestEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/AcceptTeamMemberJoinRequestEndpointResult.verified.cs new file mode 100644 index 000000000..74ca2e1ba --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/AcceptTeamMemberJoinRequestEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMembers; + +/// +/// Client Endpoint result. +/// Description: Approve a team member who requested to join a team. +/// Operation: AcceptTeamMemberJoinRequest. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class AcceptTeamMemberJoinRequestEndpointResult : EndpointResponse, IAcceptTeamMemberJoinRequestEndpointResult +{ + public AcceptTeamMemberJoinRequestEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public TeamMember OkContent + => IsOk && ContentObject is TeamMember result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/DeleteTeamMemberEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/DeleteTeamMemberEndpoint.verified.cs index 086cafb12..c65fbebf3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/DeleteTeamMemberEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/DeleteTeamMemberEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteTeamMemberEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/DeleteTeamMemberEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/DeleteTeamMemberEndpointResult.verified.cs index 8aa238f6b..dde83b702 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/DeleteTeamMemberEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/DeleteTeamMemberEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMemberEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMemberEndpoint.verified.cs index 3077d77b8..b4c1a196b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMemberEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMemberEndpoint.verified.cs @@ -39,9 +39,11 @@ public async Task ExecuteAsync( using var response = await client.SendAsync(requestMessage, cancellationToken); var responseBuilder = httpMessageFactory.FromResponse(response); - responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetTeamMemberEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMemberEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMemberEndpointResult.verified.cs index ccd67afd4..8dd1d3de3 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMemberEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMemberEndpointResult.verified.cs @@ -28,8 +28,14 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; - public TeamMemberDto OkContent - => IsOk && ContentObject is TeamMemberDto result + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public TeamMember OkContent + => IsOk && ContentObject is TeamMember result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMembersEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMembersEndpoint.verified.cs index 9c5ec1805..4c58a0ad1 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMembersEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMembersEndpoint.verified.cs @@ -52,6 +52,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetTeamMembersEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMembersEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMembersEndpointResult.verified.cs index 7b08d96b7..d35c818b9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMembersEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/GetTeamMembersEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageTeamMemberDto OkContent => IsOk && ContentObject is MontaPageTeamMemberDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IAcceptTeamMemberJoinRequestEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IAcceptTeamMemberJoinRequestEndpoint.verified.cs new file mode 100644 index 000000000..7a3f84b72 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IAcceptTeamMemberJoinRequestEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMembers.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Approve a team member who requested to join a team. +/// Operation: AcceptTeamMemberJoinRequest. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IAcceptTeamMemberJoinRequestEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + AcceptTeamMemberJoinRequestParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IAcceptTeamMemberJoinRequestEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IAcceptTeamMemberJoinRequestEndpointResult.verified.cs new file mode 100644 index 000000000..91d2aaf11 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IAcceptTeamMemberJoinRequestEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.TeamMembers.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Approve a team member who requested to join a team. +/// Operation: AcceptTeamMemberJoinRequest. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IAcceptTeamMemberJoinRequestEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + TeamMember OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IDeleteTeamMemberEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IDeleteTeamMemberEndpointResult.verified.cs index 1b869fda8..06a0d90ad 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IDeleteTeamMemberEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IDeleteTeamMemberEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IDeleteTeamMemberEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IDeleteTeamMemberEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IGetTeamMemberEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IGetTeamMemberEndpointResult.verified.cs index c1a2d3bf4..0bbf7da32 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IGetTeamMemberEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IGetTeamMemberEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetTeamMemberEndpointResult : IEndpointResponse bool IsUnauthorized { get; } - TeamMemberDto OkContent { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + + TeamMember OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IGetTeamMembersEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IGetTeamMembersEndpointResult.verified.cs index b529fc5e3..2076cf53a 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IGetTeamMembersEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IGetTeamMembersEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetTeamMembersEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageTeamMemberDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IPatchTeamMemberEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IPatchTeamMemberEndpointResult.verified.cs index 7132965b7..a73f4d47b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IPatchTeamMemberEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IPatchTeamMemberEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IPatchTeamMemberEndpointResult : IEndpointResponse bool IsUnauthorized { get; } - TeamMemberDto OkContent { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + + TeamMember OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IPostTeamMemberEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IPostTeamMemberEndpointResult.verified.cs index f4a98bdb2..641d8660c 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IPostTeamMemberEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IPostTeamMemberEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPostTeamMemberEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPostTeamMemberEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IResendTeamMemberInviteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IResendTeamMemberInviteEndpointResult.verified.cs index c2f901b17..e7fe97fb9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IResendTeamMemberInviteEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/Interfaces/IResendTeamMemberInviteEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IResendTeamMemberInviteEndpointResult : IEndpointResponse bool IsUnauthorized { get; } - TeamMemberDto OkContent { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + + TeamMember OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PatchTeamMemberEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PatchTeamMemberEndpoint.verified.cs index ab7dde1d3..80e90b594 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PatchTeamMemberEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PatchTeamMemberEndpoint.verified.cs @@ -40,9 +40,11 @@ public async Task ExecuteAsync( using var response = await client.SendAsync(requestMessage, cancellationToken); var responseBuilder = httpMessageFactory.FromResponse(response); - responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PatchTeamMemberEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PatchTeamMemberEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PatchTeamMemberEndpointResult.verified.cs index 620a378a3..9bbcf0d20 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PatchTeamMemberEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PatchTeamMemberEndpointResult.verified.cs @@ -28,8 +28,14 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; - public TeamMemberDto OkContent - => IsOk && ContentObject is TeamMemberDto result + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public TeamMember OkContent + => IsOk && ContentObject is TeamMember result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PostTeamMemberEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PostTeamMemberEndpoint.verified.cs index a2cfc4391..8180296ea 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PostTeamMemberEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PostTeamMemberEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PostTeamMemberEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PostTeamMemberEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PostTeamMemberEndpointResult.verified.cs index ead46e5d8..7795e4d72 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PostTeamMemberEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/PostTeamMemberEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/ResendTeamMemberInviteEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/ResendTeamMemberInviteEndpoint.verified.cs index d80bca490..60e8083ab 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/ResendTeamMemberInviteEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/ResendTeamMemberInviteEndpoint.verified.cs @@ -39,9 +39,11 @@ public async Task ExecuteAsync( using var response = await client.SendAsync(requestMessage, cancellationToken); var responseBuilder = httpMessageFactory.FromResponse(response); - responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new ResendTeamMemberInviteEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/ResendTeamMemberInviteEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/ResendTeamMemberInviteEndpointResult.verified.cs index 19a90b0e9..bb97301d2 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/ResendTeamMemberInviteEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/TeamMembers/ResendTeamMemberInviteEndpointResult.verified.cs @@ -28,8 +28,14 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; - public TeamMemberDto OkContent - => IsOk && ContentObject is TeamMemberDto result + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public TeamMember OkContent + => IsOk && ContentObject is TeamMember result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/DeleteTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/DeleteTeamEndpoint.verified.cs index d7d25be63..548a13796 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/DeleteTeamEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/DeleteTeamEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteTeamEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/DeleteTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/DeleteTeamEndpointResult.verified.cs index 83ae031ec..63ae99220 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/DeleteTeamEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/DeleteTeamEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/FreezeTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/FreezeTeamEndpoint.verified.cs new file mode 100644 index 000000000..751bf1d12 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/FreezeTeamEndpoint.verified.cs @@ -0,0 +1,50 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Teams; + +/// +/// Client Endpoint. +/// Description: Freeze a team. +/// Operation: FreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class FreezeTeamEndpoint : IFreezeTeamEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public FreezeTeamEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + FreezeTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/teams/{id}/freeze"); + requestBuilder.WithPathParameter("id", parameters.Id); + requestBuilder.WithBody(parameters.Request); + + using var requestMessage = requestBuilder.Build(HttpMethod.Post); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new FreezeTeamEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/FreezeTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/FreezeTeamEndpointResult.verified.cs new file mode 100644 index 000000000..35a9ee9c4 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/FreezeTeamEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Teams; + +/// +/// Client Endpoint result. +/// Description: Freeze a team. +/// Operation: FreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class FreezeTeamEndpointResult : EndpointResponse, IFreezeTeamEndpointResult +{ + public FreezeTeamEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public Team OkContent + => IsOk && ContentObject is Team result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamEndpoint.verified.cs index 34ac098ca..35567ed64 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetTeamEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamEndpointResult.verified.cs index 26649d1b3..93d7e7003 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Team OkContent => IsOk && ContentObject is Team result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamsEndpoint.verified.cs index e0fc5cd25..8bc7deaf4 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamsEndpoint.verified.cs @@ -33,8 +33,6 @@ public async Task ExecuteAsync( var client = factory.CreateClient(httpClientName); var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/teams"); - requestBuilder.WithQueryParameter("partnerExternalId", parameters.PartnerExternalId); - requestBuilder.WithQueryParameter("includeDeleted", parameters.IncludeDeleted); requestBuilder.WithQueryParameter("page", parameters.Page); requestBuilder.WithQueryParameter("perPage", parameters.PerPage); @@ -45,6 +43,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetTeamsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamsEndpointResult.verified.cs index 5e70cced0..eb3ae6bd7 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/GetTeamsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageTeamDto OkContent => IsOk && ContentObject is MontaPageTeamDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IDeleteTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IDeleteTeamEndpointResult.verified.cs index e25ba1025..87f491152 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IDeleteTeamEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IDeleteTeamEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IDeleteTeamEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IDeleteTeamEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IFreezeTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IFreezeTeamEndpoint.verified.cs new file mode 100644 index 000000000..dc364bbcf --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IFreezeTeamEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Teams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Freeze a team. +/// Operation: FreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IFreezeTeamEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + FreezeTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IFreezeTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IFreezeTeamEndpointResult.verified.cs new file mode 100644 index 000000000..05480ae21 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IFreezeTeamEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Teams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Freeze a team. +/// Operation: FreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IFreezeTeamEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + Team OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IGetTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IGetTeamEndpointResult.verified.cs index 9e4a4f611..38649fe33 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IGetTeamEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IGetTeamEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetTeamEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + Team OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IGetTeamsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IGetTeamsEndpointResult.verified.cs index 8b3f9591e..0ece95f28 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IGetTeamsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IGetTeamsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetTeamsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageTeamDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IPatchTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IPatchTeamEndpointResult.verified.cs index 2d408d5b2..c320866e1 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IPatchTeamEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IPatchTeamEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPatchTeamEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + Team OkContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPatchTeamEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IPostTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IPostTeamEndpointResult.verified.cs index 7fabca63b..8ee6efe17 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IPostTeamEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IPostTeamEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPostTeamEndpointResult : IEndpointResponse bool IsForbidden { get; } + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPostTeamEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IUnfreezeTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IUnfreezeTeamEndpoint.verified.cs new file mode 100644 index 000000000..c28b1bc46 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IUnfreezeTeamEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Teams.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Unfreeze a team. +/// Operation: UnfreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IUnfreezeTeamEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + UnfreezeTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IUnfreezeTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IUnfreezeTeamEndpointResult.verified.cs new file mode 100644 index 000000000..ee9fdb563 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/Interfaces/IUnfreezeTeamEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Teams.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Unfreeze a team. +/// Operation: UnfreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IUnfreezeTeamEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + Team OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PatchTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PatchTeamEndpoint.verified.cs index 2b2f953a4..2dd89335e 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PatchTeamEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PatchTeamEndpoint.verified.cs @@ -44,6 +44,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PatchTeamEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PatchTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PatchTeamEndpointResult.verified.cs index 2117dc2f8..cd9e78208 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PatchTeamEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PatchTeamEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public Team OkContent => IsOk && ContentObject is Team result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PostTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PostTeamEndpoint.verified.cs index 98ef25823..4d5fb68c7 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PostTeamEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PostTeamEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PostTeamEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PostTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PostTeamEndpointResult.verified.cs index d48211248..e30f6eced 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PostTeamEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/PostTeamEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/UnfreezeTeamEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/UnfreezeTeamEndpoint.verified.cs new file mode 100644 index 000000000..bbc3f1abf --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/UnfreezeTeamEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Teams; + +/// +/// Client Endpoint. +/// Description: Unfreeze a team. +/// Operation: UnfreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UnfreezeTeamEndpoint : IUnfreezeTeamEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public UnfreezeTeamEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + UnfreezeTeamParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/teams/{id}/unfreeze"); + requestBuilder.WithPathParameter("id", parameters.Id); + + using var requestMessage = requestBuilder.Build(HttpMethod.Post); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new UnfreezeTeamEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/UnfreezeTeamEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/UnfreezeTeamEndpointResult.verified.cs new file mode 100644 index 000000000..84a4a1b73 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Teams/UnfreezeTeamEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Teams; + +/// +/// Client Endpoint result. +/// Description: Unfreeze a team. +/// Operation: UnfreezeTeam. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class UnfreezeTeamEndpointResult : EndpointResponse, IUnfreezeTeamEndpointResult +{ + public UnfreezeTeamEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public Team OkContent + => IsOk && ContentObject is Team result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUserEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUserEndpoint.verified.cs new file mode 100644 index 000000000..b404d44b8 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUserEndpoint.verified.cs @@ -0,0 +1,49 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Users; + +/// +/// Client Endpoint. +/// Description: Retrieve a user. +/// Operation: GetUser. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetUserEndpoint : IGetUserEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetUserEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetUserParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/users/{userId}"); + requestBuilder.WithPathParameter("userId", parameters.UserId); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetUserEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PatchTransactionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUserEndpointResult.verified.cs similarity index 72% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PatchTransactionEndpointResult.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUserEndpointResult.verified.cs index 61aa9c560..05d8d5146 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PatchTransactionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUserEndpointResult.verified.cs @@ -4,17 +4,17 @@ // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. //------------------------------------------------------------------------------ -namespace Monta.ApiClient.Generated.Endpoints.WalletTransactions; +namespace Monta.ApiClient.Generated.Endpoints.Users; /// /// Client Endpoint result. -/// Description: Patch an existing transaction. -/// Operation: PatchTransaction. +/// Description: Retrieve a user. +/// Operation: GetUser. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public class PatchTransactionEndpointResult : EndpointResponse, IPatchTransactionEndpointResult +public class GetUserEndpointResult : EndpointResponse, IGetUserEndpointResult { - public PatchTransactionEndpointResult(EndpointResponse response) + public GetUserEndpointResult(EndpointResponse response) : base(response) { } @@ -31,8 +31,11 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; - public WalletTransaction OkContent - => IsOk && ContentObject is WalletTransaction result + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public User OkContent + => IsOk && ContentObject is User result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUsersEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUsersEndpoint.verified.cs new file mode 100644 index 000000000..e9f859ecc --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUsersEndpoint.verified.cs @@ -0,0 +1,53 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Users; + +/// +/// Client Endpoint. +/// Description: Retrieve users. +/// Operation: GetUsers. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetUsersEndpoint : IGetUsersEndpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetUsersEndpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetUsersParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/users"); + requestBuilder.WithQueryParameter("page", parameters.Page); + requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithQueryParameter("email", parameters.Email); + requestBuilder.WithQueryParameter("phone", parameters.Phone); + requestBuilder.WithQueryParameter("includeDeleted", parameters.IncludeDeleted); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetUsersEndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUsersEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUsersEndpointResult.verified.cs new file mode 100644 index 000000000..f383fbb83 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/GetUsersEndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Users; + +/// +/// Client Endpoint result. +/// Description: Retrieve users. +/// Operation: GetUsers. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetUsersEndpointResult : EndpointResponse, IGetUsersEndpointResult +{ + public GetUsersEndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageUserDto OkContent + => IsOk && ContentObject is MontaPageUserDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUserEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUserEndpoint.verified.cs new file mode 100644 index 000000000..e77abf6b8 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUserEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Users.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve a user. +/// Operation: GetUser. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetUserEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetUserParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUserEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUserEndpointResult.verified.cs new file mode 100644 index 000000000..5242423b7 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUserEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Users.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve a user. +/// Operation: GetUser. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetUserEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + User OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUsersEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUsersEndpoint.verified.cs new file mode 100644 index 000000000..7e8e03fc5 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUsersEndpoint.verified.cs @@ -0,0 +1,27 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Users.Interfaces; + +/// +/// Interface for Client Endpoint. +/// Description: Retrieve users. +/// Operation: GetUsers. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetUsersEndpoint +{ + /// + /// Execute method. + /// + /// The parameters. + /// The http client name. + /// The cancellation token. + Task ExecuteAsync( + GetUsersParameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUsersEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUsersEndpointResult.verified.cs new file mode 100644 index 000000000..843063ba0 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Users/Interfaces/IGetUsersEndpointResult.verified.cs @@ -0,0 +1,37 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.Users.Interfaces; + +/// +/// Interface for Client Endpoint Result. +/// Description: Retrieve users. +/// Operation: GetUsers. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public interface IGetUsersEndpointResult : IEndpointResponse +{ + + bool IsOk { get; } + + bool IsBadRequest { get; } + + bool IsUnauthorized { get; } + + bool IsForbidden { get; } + + bool IsNotFound { get; } + + MontaPageUserDto OkContent { get; } + + string? BadRequestContent { get; } + + string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactions1Endpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactions1Endpoint.verified.cs new file mode 100644 index 000000000..945708c63 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactions1Endpoint.verified.cs @@ -0,0 +1,50 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.WalletTransactions; + +/// +/// Client Endpoint. +/// Description: Retrieves wallet transactions for an invoice. +/// Operation: GetWalletTransactions1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetWalletTransactions1Endpoint : IGetWalletTransactions1Endpoint +{ + private readonly IHttpClientFactory factory; + private readonly IHttpMessageFactory httpMessageFactory; + + public GetWalletTransactions1Endpoint( + IHttpClientFactory factory, + IHttpMessageFactory httpMessageFactory) + { + this.factory = factory; + this.httpMessageFactory = httpMessageFactory; + } + + public async Task ExecuteAsync( + GetWalletTransactions1Parameters parameters, + string httpClientName = "Monta-ApiClient", + CancellationToken cancellationToken = default) + { + var client = factory.CreateClient(httpClientName); + + var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/wallet-transactions/invoices/{invoiceId}"); + requestBuilder.WithPathParameter("invoiceId", parameters.InvoiceId); + requestBuilder.WithQueryParameter("pageable", parameters.Pageable); + + using var requestMessage = requestBuilder.Build(HttpMethod.Get); + using var response = await client.SendAsync(requestMessage, cancellationToken); + + var responseBuilder = httpMessageFactory.FromResponse(response); + responseBuilder.AddSuccessResponse(HttpStatusCode.OK); + responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); + responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); + return await responseBuilder.BuildResponseAsync(x => new GetWalletTransactions1EndpointResult(x), cancellationToken); + } +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactions1EndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactions1EndpointResult.verified.cs new file mode 100644 index 000000000..a57543f25 --- /dev/null +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactions1EndpointResult.verified.cs @@ -0,0 +1,61 @@ +//------------------------------------------------------------------------------ +// This code was auto-generated by ApiGenerator x.x.x.x. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +//------------------------------------------------------------------------------ +namespace Monta.ApiClient.Generated.Endpoints.WalletTransactions; + +/// +/// Client Endpoint result. +/// Description: Retrieves wallet transactions for an invoice. +/// Operation: GetWalletTransactions1. +/// +[GeneratedCode("ApiGenerator", "x.x.x.x")] +public class GetWalletTransactions1EndpointResult : EndpointResponse, IGetWalletTransactions1EndpointResult +{ + public GetWalletTransactions1EndpointResult(EndpointResponse response) + : base(response) + { + } + + public bool IsOk + => StatusCode == HttpStatusCode.OK; + + public bool IsBadRequest + => StatusCode == HttpStatusCode.BadRequest; + + public bool IsUnauthorized + => StatusCode == HttpStatusCode.Unauthorized; + + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + + public MontaPageWalletTransactionDto OkContent + => IsOk && ContentObject is MontaPageWalletTransactionDto result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsOk property first."); + + public string? BadRequestContent + => IsBadRequest && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsBadRequest property first."); + + public string? UnauthorizedContent + => IsUnauthorized && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); +} \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactionsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactionsEndpoint.verified.cs index e8353da63..a84780893 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactionsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactionsEndpoint.verified.cs @@ -35,6 +35,7 @@ public async Task ExecuteAsync( var requestBuilder = httpMessageFactory.FromTemplate("/api/v1/wallet-transactions"); requestBuilder.WithQueryParameter("page", parameters.Page); requestBuilder.WithQueryParameter("perPage", parameters.PerPage); + requestBuilder.WithQueryParameter("operatorId", parameters.OperatorId); requestBuilder.WithQueryParameter("teamId", parameters.TeamId); requestBuilder.WithQueryParameter("fromDate", parameters.FromDate); requestBuilder.WithQueryParameter("toDate", parameters.ToDate); @@ -51,6 +52,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetWalletTransactionsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactionsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactionsEndpointResult.verified.cs index 140427e88..cd55001ce 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactionsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/GetWalletTransactionsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageWalletTransactionDto OkContent => IsOk && ContentObject is MontaPageWalletTransactionDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPatchTransactionEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactions1Endpoint.verified.cs similarity index 76% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPatchTransactionEndpoint.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactions1Endpoint.verified.cs index a5106487b..5f5367615 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPatchTransactionEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactions1Endpoint.verified.cs @@ -8,11 +8,11 @@ namespace Monta.ApiClient.Generated.Endpoints.WalletTransactions.Interfaces; /// /// Interface for Client Endpoint. -/// Description: Patch an existing transaction. -/// Operation: PatchTransaction. +/// Description: Retrieves wallet transactions for an invoice. +/// Operation: GetWalletTransactions1. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public interface IPatchTransactionEndpoint +public interface IGetWalletTransactions1Endpoint { /// /// Execute method. @@ -20,8 +20,8 @@ public interface IPatchTransactionEndpoint /// The parameters. /// The http client name. /// The cancellation token. - Task ExecuteAsync( - PatchTransactionParameters parameters, + Task ExecuteAsync( + GetWalletTransactions1Parameters parameters, string httpClientName = "Monta-ApiClient", CancellationToken cancellationToken = default); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPatchTransactionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactions1EndpointResult.verified.cs similarity index 71% rename from test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPatchTransactionEndpointResult.verified.cs rename to test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactions1EndpointResult.verified.cs index 42a865a0a..c3f9efe6f 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPatchTransactionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactions1EndpointResult.verified.cs @@ -8,11 +8,11 @@ namespace Monta.ApiClient.Generated.Endpoints.WalletTransactions.Interfaces; /// /// Interface for Client Endpoint Result. -/// Description: Patch an existing transaction. -/// Operation: PatchTransaction. +/// Description: Retrieves wallet transactions for an invoice. +/// Operation: GetWalletTransactions1. /// [GeneratedCode("ApiGenerator", "x.x.x.x")] -public interface IPatchTransactionEndpointResult : IEndpointResponse +public interface IGetWalletTransactions1EndpointResult : IEndpointResponse { bool IsOk { get; } @@ -23,11 +23,15 @@ public interface IPatchTransactionEndpointResult : IEndpointResponse bool IsForbidden { get; } - WalletTransaction OkContent { get; } + bool IsNotFound { get; } + + MontaPageWalletTransactionDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactionsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactionsEndpointResult.verified.cs index a4954757f..31a04b271 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactionsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IGetWalletTransactionsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetWalletTransactionsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageWalletTransactionDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPostOperatorAdjustmentTransactionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPostOperatorAdjustmentTransactionEndpointResult.verified.cs index 07c5fbf93..5a5a4cfa6 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPostOperatorAdjustmentTransactionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/Interfaces/IPostOperatorAdjustmentTransactionEndpointResult.verified.cs @@ -23,6 +23,8 @@ public interface IPostOperatorAdjustmentTransactionEndpointResult : IEndpointRes bool IsForbidden { get; } + bool IsNotFound { get; } + string? CreatedContent { get; } string? BadRequestContent { get; } @@ -30,4 +32,6 @@ public interface IPostOperatorAdjustmentTransactionEndpointResult : IEndpointRes string? UnauthorizedContent { get; } string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PostOperatorAdjustmentTransactionEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PostOperatorAdjustmentTransactionEndpoint.verified.cs index fe29a31b0..8d3b9b2cc 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PostOperatorAdjustmentTransactionEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PostOperatorAdjustmentTransactionEndpoint.verified.cs @@ -43,6 +43,7 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new PostOperatorAdjustmentTransactionEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PostOperatorAdjustmentTransactionEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PostOperatorAdjustmentTransactionEndpointResult.verified.cs index d5364ec6c..065441866 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PostOperatorAdjustmentTransactionEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/WalletTransactions/PostOperatorAdjustmentTransactionEndpointResult.verified.cs @@ -31,6 +31,9 @@ public bool IsUnauthorized public bool IsForbidden => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? CreatedContent => IsCreated && ContentObject is string result ? result @@ -50,4 +53,9 @@ public string? ForbiddenContent => IsForbidden && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/GetWalletsEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/GetWalletsEndpoint.verified.cs index 901fcca7b..5e2813fee 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/GetWalletsEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/GetWalletsEndpoint.verified.cs @@ -45,6 +45,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetWalletsEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/GetWalletsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/GetWalletsEndpointResult.verified.cs index 29950740d..d7346a072 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/GetWalletsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/GetWalletsEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageWalletDto OkContent => IsOk && ContentObject is MontaPageWalletDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/Interfaces/IGetWalletsEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/Interfaces/IGetWalletsEndpointResult.verified.cs index a5873fb6e..59849609c 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/Interfaces/IGetWalletsEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Wallets/Interfaces/IGetWalletsEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetWalletsEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageWalletDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/DeleteWebhookConfigEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/DeleteWebhookConfigEndpoint.verified.cs index e1adc20b2..ce0a596fd 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/DeleteWebhookConfigEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/DeleteWebhookConfigEndpoint.verified.cs @@ -40,6 +40,8 @@ public async Task ExecuteAsync( responseBuilder.AddErrorResponse(HttpStatusCode.NoContent); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new DeleteWebhookConfigEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/DeleteWebhookConfigEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/DeleteWebhookConfigEndpointResult.verified.cs index 2125ab05d..ac5e71995 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/DeleteWebhookConfigEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/DeleteWebhookConfigEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public string? NoContentContent => IsNoContent && ContentObject is string result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookConfigEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookConfigEndpoint.verified.cs index 56d5822c5..9ae4c1471 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookConfigEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookConfigEndpoint.verified.cs @@ -40,6 +40,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetWebhookConfigEndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookConfigEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookConfigEndpointResult.verified.cs index 8d7392cff..15bd43f84 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookConfigEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookConfigEndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntries1Endpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntries1Endpoint.verified.cs index 85b1274fb..ca9e2973d 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntries1Endpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntries1Endpoint.verified.cs @@ -42,6 +42,7 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetWebhookEntries1EndpointResult(x), cancellationToken); } diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntries1EndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntries1EndpointResult.verified.cs index 965c79c81..874247c40 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntries1EndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntries1EndpointResult.verified.cs @@ -28,6 +28,9 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + public bool IsNotFound => StatusCode == HttpStatusCode.NotFound; @@ -46,6 +49,11 @@ public string? UnauthorizedContent ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + public string? NotFoundContent => IsNotFound && ContentObject is string result ? result diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntriesEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntriesEndpoint.verified.cs index 60b538cdc..80c7fba03 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntriesEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntriesEndpoint.verified.cs @@ -44,6 +44,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new GetWebhookEntriesEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntriesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntriesEndpointResult.verified.cs index eaf54cf3a..39436ad0b 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntriesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/GetWebhookEntriesEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public MontaPageWebhookEntryDto OkContent => IsOk && ContentObject is MontaPageWebhookEntryDto result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IDeleteWebhookConfigEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IDeleteWebhookConfigEndpointResult.verified.cs index 62c85ee25..1a91ce434 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IDeleteWebhookConfigEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IDeleteWebhookConfigEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IDeleteWebhookConfigEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + string? NoContentContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookConfigEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookConfigEndpointResult.verified.cs index e4dd6f18e..dca59dbf5 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookConfigEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookConfigEndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IGetWebhookConfigEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } WebhookConfig OkContent { get; } @@ -29,5 +31,7 @@ public interface IGetWebhookConfigEndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookEntries1EndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookEntries1EndpointResult.verified.cs index faa6f5157..4b1c358a9 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookEntries1EndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookEntries1EndpointResult.verified.cs @@ -21,6 +21,8 @@ public interface IGetWebhookEntries1EndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + bool IsNotFound { get; } WebhookEntry OkContent { get; } @@ -29,5 +31,7 @@ public interface IGetWebhookEntries1EndpointResult : IEndpointResponse string? UnauthorizedContent { get; } + string? ForbiddenContent { get; } + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookEntriesEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookEntriesEndpointResult.verified.cs index aca8b593b..30d67d323 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookEntriesEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IGetWebhookEntriesEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IGetWebhookEntriesEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + MontaPageWebhookEntryDto OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IUpdateWebhookConfigEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IUpdateWebhookConfigEndpointResult.verified.cs index fd39f82b2..8fffd4fa8 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IUpdateWebhookConfigEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/Interfaces/IUpdateWebhookConfigEndpointResult.verified.cs @@ -21,9 +21,17 @@ public interface IUpdateWebhookConfigEndpointResult : IEndpointResponse bool IsUnauthorized { get; } + bool IsForbidden { get; } + + bool IsNotFound { get; } + WebhookConfig OkContent { get; } string? BadRequestContent { get; } string? UnauthorizedContent { get; } + + string? ForbiddenContent { get; } + + string? NotFoundContent { get; } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/UpdateWebhookConfigEndpoint.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/UpdateWebhookConfigEndpoint.verified.cs index 65f2057f8..60a4a4260 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/UpdateWebhookConfigEndpoint.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/UpdateWebhookConfigEndpoint.verified.cs @@ -42,6 +42,8 @@ public async Task ExecuteAsync( responseBuilder.AddSuccessResponse(HttpStatusCode.OK); responseBuilder.AddErrorResponse(HttpStatusCode.BadRequest); responseBuilder.AddErrorResponse(HttpStatusCode.Unauthorized); + responseBuilder.AddErrorResponse(HttpStatusCode.Forbidden); + responseBuilder.AddErrorResponse(HttpStatusCode.NotFound); return await responseBuilder.BuildResponseAsync(x => new UpdateWebhookConfigEndpointResult(x), cancellationToken); } } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/UpdateWebhookConfigEndpointResult.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/UpdateWebhookConfigEndpointResult.verified.cs index c15938356..a73724c01 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/UpdateWebhookConfigEndpointResult.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/Endpoints/Webhooks/UpdateWebhookConfigEndpointResult.verified.cs @@ -28,6 +28,12 @@ public bool IsBadRequest public bool IsUnauthorized => StatusCode == HttpStatusCode.Unauthorized; + public bool IsForbidden + => StatusCode == HttpStatusCode.Forbidden; + + public bool IsNotFound + => StatusCode == HttpStatusCode.NotFound; + public WebhookConfig OkContent => IsOk && ContentObject is WebhookConfig result ? result @@ -42,4 +48,14 @@ public string? UnauthorizedContent => IsUnauthorized && ContentObject is string result ? result : throw new InvalidOperationException("Content is not the expected type - please use the IsUnauthorized property first."); + + public string? ForbiddenContent + => IsForbidden && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsForbidden property first."); + + public string? NotFoundContent + => IsNotFound && ContentObject is string result + ? result + : throw new InvalidOperationException("Content is not the expected type - please use the IsNotFound property first."); } \ No newline at end of file diff --git a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/GlobalUsings.verified.cs b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/GlobalUsings.verified.cs index 9ddfacb79..8cf2c8c94 100644 --- a/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/GlobalUsings.verified.cs +++ b/test/Atc.Rest.ApiGenerator.CLI.Tests/Scenarios/Monta/VerifyClient/WCEM/src/Monta.ApiClient.Generated/GlobalUsings.verified.cs @@ -22,18 +22,22 @@ global using Monta.ApiClient.Generated.Contracts.ChargePointIntegrations; global using Monta.ApiClient.Generated.Contracts.ChargePointModels; global using Monta.ApiClient.Generated.Contracts.ChargePoints; +global using Monta.ApiClient.Generated.Contracts.ChargePointStatistics; global using Monta.ApiClient.Generated.Contracts.Charges; global using Monta.ApiClient.Generated.Contracts.Countries; global using Monta.ApiClient.Generated.Contracts.CountryAreas; global using Monta.ApiClient.Generated.Contracts.Currencies; global using Monta.ApiClient.Generated.Contracts.Insights; global using Monta.ApiClient.Generated.Contracts.InstallerJobs; +global using Monta.ApiClient.Generated.Contracts.Invoices; +global using Monta.ApiClient.Generated.Contracts.NestedTeams; global using Monta.ApiClient.Generated.Contracts.Operators; global using Monta.ApiClient.Generated.Contracts.PaymentTerminals; global using Monta.ApiClient.Generated.Contracts.Plans; global using Monta.ApiClient.Generated.Contracts.PriceGroups; global using Monta.ApiClient.Generated.Contracts.PriceGroupTags; global using Monta.ApiClient.Generated.Contracts.Prices; +global using Monta.ApiClient.Generated.Contracts.Reports; global using Monta.ApiClient.Generated.Contracts.Sites; global using Monta.ApiClient.Generated.Contracts.SponsoredChargePoints; global using Monta.ApiClient.Generated.Contracts.SubscriptionPurchases; @@ -41,8 +45,10 @@ global using Monta.ApiClient.Generated.Contracts.TariffPeriodGroups; global using Monta.ApiClient.Generated.Contracts.TariffRecurringPeriods; global using Monta.ApiClient.Generated.Contracts.Tariffs; +global using Monta.ApiClient.Generated.Contracts.TeamMemberProfiles; global using Monta.ApiClient.Generated.Contracts.TeamMembers; global using Monta.ApiClient.Generated.Contracts.Teams; +global using Monta.ApiClient.Generated.Contracts.Users; global using Monta.ApiClient.Generated.Contracts.Wallets; global using Monta.ApiClient.Generated.Contracts.WalletTransactions; global using Monta.ApiClient.Generated.Contracts.Webhooks; @@ -53,6 +59,7 @@ global using Monta.ApiClient.Generated.Endpoints.ChargePointIntegrations.Interfaces; global using Monta.ApiClient.Generated.Endpoints.ChargePointModels.Interfaces; global using Monta.ApiClient.Generated.Endpoints.ChargePoints.Interfaces; +global using Monta.ApiClient.Generated.Endpoints.ChargePointStatistics.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Charges.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Consumers.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Countries.Interfaces; @@ -60,12 +67,15 @@ global using Monta.ApiClient.Generated.Endpoints.Currencies.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Insights.Interfaces; global using Monta.ApiClient.Generated.Endpoints.InstallerJobs.Interfaces; +global using Monta.ApiClient.Generated.Endpoints.Invoices.Interfaces; +global using Monta.ApiClient.Generated.Endpoints.NestedTeams.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Operators.Interfaces; global using Monta.ApiClient.Generated.Endpoints.PaymentTerminals.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Plans.Interfaces; global using Monta.ApiClient.Generated.Endpoints.PriceGroups.Interfaces; global using Monta.ApiClient.Generated.Endpoints.PriceGroupTags.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Prices.Interfaces; +global using Monta.ApiClient.Generated.Endpoints.Reports.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Sites.Interfaces; global using Monta.ApiClient.Generated.Endpoints.SponsoredChargePoints.Interfaces; global using Monta.ApiClient.Generated.Endpoints.SubscriptionPurchases.Interfaces; @@ -73,8 +83,10 @@ global using Monta.ApiClient.Generated.Endpoints.TariffPeriodGroups.Interfaces; global using Monta.ApiClient.Generated.Endpoints.TariffRecurringPeriods.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Tariffs.Interfaces; +global using Monta.ApiClient.Generated.Endpoints.TeamMemberProfiles.Interfaces; global using Monta.ApiClient.Generated.Endpoints.TeamMembers.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Teams.Interfaces; +global using Monta.ApiClient.Generated.Endpoints.Users.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Wallets.Interfaces; global using Monta.ApiClient.Generated.Endpoints.WalletTransactions.Interfaces; global using Monta.ApiClient.Generated.Endpoints.Webhooks.Interfaces; \ No newline at end of file