Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Tip
titleAXEPTA API

AXEPTA is a payment solution based on a HTTPS POST / GET API using parameters in the NVP (Name-Value-Pairs) method and JSON objects.

HMAC authentication and the use of Blowfish encryption are used to secure data exchanges.



This section covers the following topics


Table of Contents


Integration and inputs for developers

The section Inputs Platform Integration for developers gathers all inputs needed to implement Axepta Online in your website

Info


Localtab Group


Localtab
activetrue
titleIntegration and inputs for developers


Navitabs
ltruncfirsttabfalse
rootInputs Platform Integration for developers
width950
verticaltrue










La section Intégration de la solution de paiement regroupe les données utilisées par la plateforme : codes retours, données 3DS, objets JSONThe section Axepta data list gathers the parameters / data used on the platform : error codes, 3DS data, JSON objects

Info


Localtab Group


Localtab
activetrue
titleDonnées Axepta data


Navitabs
ltruncfirsttabfalse
rootIntégration de la solution de paiementAxepta data list
width950
verticaltrue








Sécurisation

Security

Authentification

HMAC

Pour vous protéger contre toute manipulation non autorisée de vos transactions de paiement, la plate-forme Axepta vérifie à l'aide d'un code d'authentification de message haché (HMAC) si votre demande de paiement est authentique et n'a pas été modifiée.Pour cela, vous transférez une valeur HMAC à la Plateforme à chaque transaction dans le paramètre MAC.

Authentication

To protect you against unauthorized manipulation of your payment transactions, Axepta platform checks with a hash message authentication code (HMAC) if your payment request is authentic and has not been modified. To do so, you transfer a HMAC value to the Platform for each transaction in the MAC parameter.


The Axepta platform uses a

La plateforme Axepta utilise un

Hash Message Authentication Code (HMAC)

pour vérifier l'authenticité de vos paiements. L'algorithme

to verify the authenticity of your payments. MAC SHA-256 algorithm is used with a 32-digit (256-bit) key length.


Further details est utilisé avec une longueur de clé à 32 chiffres (256 bits).
Pour plus de détails : HMAC Authentication (Request) et HMAC Authentication (Notify)


Blowfish ECB

Blowfish est un algorithme de chiffrement symétrique (c'est-à-dire « à clef secrète »).is a symmetric encryption algorithm (i.e., "secret key").


To ease your integration, you will find below some examples of Blowfish ECB library.

TechnoExamples

Pour faciliter votre intégration, vous trouverez ci-dessous quelques exemples de librairies Blowfish ECB 

TechnoExemples
ASPtxmsCrypto.dll // txmsCrypto.BlowFish
ASP.NETComputop.Core.Crypto.dll // Axepta.Core.Crypto.BlowFish
JavaBlowfish.java
PHP

function.inc.php

  • ctHMAC
  • ctEncrypt
  • ctDecrypt



Construire une requête de paiement

Build a payment request

Concepts

L’intégration de la solution de paiement Axepta se base principalement sur un concept de construction de requête de paiement dont les principes sont les suivants :

Axepta payment solution integration is based on a payment request build with :

  • Parameters using the Gestion des paramètres en méthode NVP (Name-Value-Pairs) method
  • Utilisation d'objets JSON
  • Le calcul d'un HMAC
  • objects
  • Calculation of a HMAC
  • A correct character string contains three basic parameters: MID (Merchant IDUne chaîne de caractères correcte contient trois paramètres de base : MerchantID (Identifiant du commerçant), Len (LongueurLength) et and Data (DonnéesData). Les paramètres MerchantID et Len ne sont pas chiffrés. Seul le paramètre Data est chiffré avec la méthode Blowfish MID and Len parameters are not encrypted. Only the parameter Data is encrypted with the Blowfish method


Parameters

  • Parameter Data (Données) contains the key data of the payment such as amount and currency
  • Parameter

Paramètres

  • Le paramètre Data (Données) comprend les détails de paiement essentiels comme le montant et la devise.
  • Le paramètre Len (Longueur) est très important pour le chiffrement, car il contient la longueur de la chaîne de caractères non chiffrée dans le paramètre Data. La quantité de données à chiffrer étant multipliée par 8 dans le cas du chiffrement Blowfish, la longueur correcte de la chaîne de caractères doit être connue pour le déchiffrement, sans quoi d’autres caractères non prévus apparaissent à la fin de la chaîne de caractères.

Les paramètres sont transmis via HTTPS POST ou HTTPS GET.

La méthode de transmission recommandée est HTTPS POST, car la chaîne de caractères du paramètre dans le cas de GET, jointe à l’URL, est limitée à 2 048 octets selon le navigateur, contrairement à la méthode POST qui n’est pas limitée par la taille de l’URL.

Etapes de création d’une requête de paiement

Les étapes de création d’une requête sont :

  • Calcul du HMAC pour sécuriser le montant et la devise
    • Chaîne de caractère à chiffer avec la clé HMAC : PayID*TransID*MerchantID*Status*Code
    • Certaines valeurs peuvent être laisser vide
  • Construire les objets JSON et les encoder en Base64 avec padding
  • Assembler les paramètres (clé / valeur, objets JSON) de l'API
  • Chiffrer tous les paramètres de l’API avec la clé Blowfish : cela permettra d’obtenir les paramètres Data et Len
  • Si besoin, ajouter des paramètres simples pour personnaliser la page de paiement hébergée par (par exemple language="en" pour utiliser la langue anglaise, les customFields)
  • Envoyer la demande d’API au endpoint choisi

Réponse

Axepta Online utilise les méthodes POST et GET pour rediriger l'utilisateur vers le site e-commerce du marchand ou envoyer la notification du résultat du paiement

Moyen de paiement choisi par l'acheteur

Format des réponses

Paiements carte

Méthode POST pour l’URLFailure / URLSuccess / URLNotify

Méthode GET pour l’URLFailure / URLSuccess / URLNotify en cas de fallback 3DSV1

Moyens de paiement alternatifs

Méthode GET pour l’URLFailure / URLSuccess / URLNotify

Exemple pas à pas

  • is very important for encryption because it contains the length of the unencrypted string in the Data parameter. The total amount of encrypted data is multiplied by 8 with the Blowfish encryption, so the correct (real) length of the string of characters must be known for decryption, otherwise other characters (not initially added) will appear at the end of the string.


The parameters are transmitted via HTTPS POST or HTTPS GET.

The recommended transmit method is HTTPS POST because the parameter character string in the case of GET is attached to the URL, which is limited to 2048 bytes depending on the browser.


Create a payment request step by step

The steps are :

  • Calculate HMAC to secure amount and currency - cf. HMAC Authentication (Request)
  • Build and encode JSON objects in Base64 with padding - cf. Payment Features
  • Assemble API parameters (key / value, JSON objects)
  • Encryption of all API parameters with the Blowfish key: this will provide the Data and Len parameters
  • If necessary, add simple parameters to customize the payment page hosted by (e.g. language="en" to use the English language, customFields)
  • Sending the API application to the selected endpoint



Response

Axepta Online uses the POST and GET methods to redirect the buyer to the merchant's e-commerce site or send the payment notification

Payment method

Reponses

Card payments

POST for l’URLFailure / URLSuccess / URLNotify

GET for l’URLFailure / URLSuccess / URLNotify  fallback 3DSV1

Other payment methods

GET for l’URLFailure / URLSuccess / URLNotify




Example


Tip

The page Create a payment request step by step describes the step to create a payment with BNP_DEMO_AXEPTA.

This can be the first step in your integration then you will use your own MID

Tip

La page Créer une requête de paiement pas à pas permet de réaliser un premier paiement via la boutique de démo BNP_DEMO_AXEPTA.

Après cette première étape vous pourrez utiliser les données d'accès transmis lors de votre souscription.