Skip to content

kjetilmk/Epinova.ArvatoPaymentGateway

 
 

Repository files navigation

Epinova.ArvatoPaymentGateway

Epinova's take on Arvato's AfterPay payment gateway API. All about invoices and down payment plans.

Quality Gate Status Build status Tests License: MIT

Getting Started

Configuration

No configuration via config files are needed, but you can set up different API endpoint addresses for different environments via an appSetting.

web.config:

<configuration>
    <appSettings>
      <!-- Test environment: -->
      <add key="AfterPay.Api.BaseAddress" value="https://sandboxapi.horizonafs.com/eCommerceServicesWebApi/" />
      <!-- Production environment: -->
      <add key="AfterPay.Api.BaseAddress" value="https://api.afterpay.io/" />
    <appSettings>
</configuration>

If not provided the production URL is used by default.

Add registry to IoC container

If using Structuremap:

container.Configure(
    x =>
    {
        x.Scan(y =>
        {
            y.TheCallingAssembly();
            y.WithDefaultConventions();
        });

        x.AddRegistry<Epinova.ArvatoPaymentGateway.InvoiceGatewayRegistry>();
    });

If you cannot use the structuremap registry provided with this module, you can manually set up InvoiceGatewayService for IInvoiceGatewayService & ICustomerLookupService.

Inject contract and use service

Epinova.ArvatoPaymentGateway.IInvoiceGatewayService describes the main invoice gateway service. Epinova.ArvatoPaymentGateway.ICustomerLookupService describes the customer lookup service.

Prerequisites

Installing

The module is published on nuget.org.

nuget install Epinova.ArvatoPaymentGateway

Target framework

  • .NET Standard 2.0
  • Tests target .NET Core 2.1

Authors

  • Tarjei Olsen - Initial work - apeneve

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE file for details

Further reading

AfterPay API documentation

About

Epinova's take on Arvato's AfterPay payment gateway API

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 96.1%
  • Smalltalk 3.9%