Contenu du cours

Merchant Webservice 

The sections covers the Webservice example which the merchant can implement in order to consume the transaction responses as and when they are delivered by the Gateway's out of band notification system.

Out of Band Sample:

namespace 

{

       public class Response: IResponse

  {

            public string TransactionResponse(Response_message message)

   {

                      string decoded_response = null;

                      string response_message = null;

                      string response = message.message;

                    //Deserialize the message and get the response

                     dynamic dynJson = JsonConvert.DeserializeObject(response);

                     string deserialized_response = dynJson.Response;

                     //Decode the response from base64

                    byte [] response_data = System.Convert.FromBase64String(deserialized_response);

                    decoded_response = System.Text.ASCIIEncoding.ASCII.GetString(response_data);

                    response_message = decoded_response;

                    Log.WriteLog(response_message);

                    return response_message;

         }

     }

}





Vues
344 Total des vues
1 Vues Membres
675 Vues publiques
Actions
0 Aime
0 N'aime pas
0 Commentaires
Partager sur des réseaux sociaux
Partager le lien
Partager par email

S'il vous plaît S'identifier afin de partager ce webpage par email