feat: add payment providers Adyen, PayU, Przelewy24, Tpay, HotPay, PayNow, Revolut#25
Merged
nieprzecietny merged 5 commits intomasterfrom Mar 24, 2026
Merged
Conversation
added 2 commits
March 24, 2026 15:11
…yNow, Revolut Nowe biblioteki implementujące IPaymentProvider: - Adyen — oficjalny SDK (Adyen v14), Sessions API, HMAC-SHA256 webhook - PayU — OAuth2 + REST API v2.1, MD5/SHA256 OpenPayU-Signature - Przelewy24 — REST API v1, SHA384 CRC sign verification - Tpay — OAuth2 + REST API, SHA256 SecurityCode webhook - HotPay — SHA256 hash, redirect flow - PayNow (mBank) — REST API v2, HMAC-SHA256 Signature header - Revolut — REST API 1.0, HMAC-SHA256 Revolut-Signature (v1=<hex>) Każdy provider: - Single-file (Options, Interface, Caller, Provider, Extensions, ConfigureOptions) - IHttpClientFactory z nazwanym klientem (poza Adyen) - Per-request weryfikacja podpisu webhooka - GetPaymentChannels() z hardcoded listą (analog Stripe) - Konfiguracja z sekcji Payments:Providers:<Name> Testy: - MultiProviderPaymentTest.cs — smoke testy (channels, providers list, invalid webhook → Rejected) - 2 integracyjne (Skip) dla PayU i Revolut Pozostałe zmiany: - TailoredApps.Shared.sln — 7 nowych wpisów projektów - test csproj — 7 nowych ProjectReference - appsettings.json — placeholder config dla każdego providera
Błędy kompilacji: - AdyenProvider.cs: usunięto Adyen SDK (Adyen.Model.Enum.Environment nie istnieje w v14); zastąpiono czystym HttpClient → Adyen Checkout REST API v71/sessions - Adyen.csproj: usunięto pakiet Adyen v14, dodano Microsoft.Extensions.Http - PayUProvider.cs: PaymentModel.Installment → PaymentModel.OneTime (enum nie ma Installment) CS1591 XML docs (pre-existing, brak komentarzy): - TailoredApps.Shared.Email.Models/MailMessage.cs - TailoredApps.Shared.MediatR.Caching/ICachableRequest.cs - TailoredApps.Shared.MediatR/Caching/Cache.cs - TailoredApps.Shared.MediatR/DI/PipelineRegistration.cs - TailoredApps.Shared.MediatR/Interfaces/Caching/ICache.cs - TailoredApps.Shared.MediatR/Interfaces/Caching/ICachePolicy.cs - TailoredApps.Shared.MediatR/Interfaces/DI/IPipelineRegistration.cs - TailoredApps.Shared.MediatR/Interfaces/Handlers/IFallbackHandler.cs - TailoredApps.Shared.MediatR/Interfaces/Messages/IRetryableRequest.cs - TailoredApps.Shared.MediatR/PipelineBehaviours/FallbackBehavior.cs - TailoredApps.Shared.MediatR/PipelineBehaviours/LoggingBehavior.cs - TailoredApps.Shared.MediatR/PipelineBehaviours/RetryBehavior.cs - TailoredApps.Shared.MediatR/PipelineBehaviours/ValidationBehavior.cs - TailoredApps.Shared.Querying/IPagedResult.cs - TailoredApps.Shared.Querying/PagedAndSortedQuery.cs (wszystkie interfejsy) - TailoredApps.Shared.Querying/QueryBase.cs - TailoredApps.Shared.Querying/QueryMap.cs - TailoredApps.Shared.Querying/SortDirection.cs CS0108 new keyword (PagedAndSortedQuery.cs): - IPagedAndSortedQuery<TQuery>: Page, Count, IsPagingSpecified, SortField, SortDir, IsSortingSpecified, Filter teraz mają słowo kluczowe new
Naprawa błędu testu: - MultiProviderPaymentTest.cs: Provider_HasCorrectUrl → Provider_HasCorrectName (PaymentProvider model nie ma property Url, tylko Id i Name) XML docs — brakujące komentarze w 6 providerach: - PayUProvider.cs (pełne docs z summary + inheritdoc) - Przelewy24Provider.cs, TpayProvider.cs, HotPayProvider.cs, PayNowProvider.cs, RevolutProvider.cs (docs via skrypt) - StripeProvider.cs, StripeServiceCaller.cs, StripeServiceOptions.cs XML docs — pre-existing projekty Email: - SmtpEmailProvider.cs, SmtpEmailServiceOptions.cs - IEmailProvider.cs, EmailServiceToConsolleWritter.cs - MailMessageBuilder/* (DefaultMessageBuilder, IMailMessageBuilder, TokenReplacingMailMessageBuilder, TokenReplacingMailMessageBuilderOptions) CashBill: - <NoWarn>SYSLIB0014</NoWarn> — WebRequest.Create obsolete warning
added 2 commits
March 24, 2026 15:52
Dopisane brakujące summary na poziomie klasy/interfejsu (skrypt nie łapał deklaracji typów — tylko members): - IEmailProvider, EmailServiceToConsolleWritter - IMailMessageBuilder, DefaultMessageBuilder - TokenReplacingMailMessageBuilder, TokenReplacingMailMessageBuilderOptions
…mailServiceOptions
szeregowy-agent
pushed a commit
that referenced
this pull request
Mar 24, 2026
Commity które nie weszły przy merge PR #25 (branch był na f14270c): - XML docs: ExceptionHandling (IExceptionHandlingProvider, IExceptionHandlingOptionsBuilder, ExceptionOccuredResult) - XML docs: SmtpEmailConfigureOptions - XML docs: wszystkie 7 providerów (Adyen, PayU, P24, Tpay, HotPay, PayNow, Revolut) - XML docs: Stripe, Email, MediatR, Querying - CashBill: <NoWarn>SYSLIB0014</NoWarn> - Testy: ProviderUnitTests.cs (65+ testów z Moq) - Testy: ServiceCallerUnitTests.cs (~45 testów ServiceCallerów — czyste funkcje) - Tests.csproj: Moq v4 dependency
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Nowe providery płatności
Implementuje 7 nowych bibliotek
IPaymentProvideranalogicznie do istniejących CashBill i Stripe.Providery
Adyen v14.*(oficjalny SDK)Architektura (każdy provider)
IHttpClientFactoryz nazwanym klientem (poza Adyen który używa własnego SDK)GetPaymentChannels()— hardcoded lista (analog Stripe)Payments:Providers:<Name>net8.0;net9.0;net10.0Testy
MultiProviderPaymentTest.cs— smoke testy (rejestracja providerów, listy kanałów, invalid webhook → Rejected)Konfiguracja
Placeholder keys dodane do
appsettings.jsonw projekcie testowym — zastąpić prawdziwymi credentials sandbox.