Skip to main content
knowledgecenter.2checkout.com

Use WebMoney

Overview

Place an order with catalog products defined in your Merchant Control Panel and collect the payment using WebMoney.

Requirements

Shoppers in the CIS (Commonwealth of Independent States) area, Russia, and Asia (Malaysia, Indonesia) can purchase using WebMoney. 

Supported currencies

WebMoney supports transactions in USD.

Workflow

  1. If the shopper is paying with any one of the supported currencies, they can use WebMoney as a payment method in the shopping cart.
  2. After the order is generated by calling the placeOrder method, in the order's details the shopper will find a URL where they need to be redirected in order to finish the payment.
  3. The URL can be found in the PaymentDetails/PaymentMethod response object, under the Redirect attribute. The shopper needs to be redirected to that URL via a POST call, with the parameters available in the API response sent to the URL.
  4. Once the shopper finishes the payment process on the WebMoney side, the order will be updated in the 2Checkout system as well.

Parameters

Parameters Type/Description

sessionID

Required (string)

 

Session identifier, the output of the Login method. Include sessionID into all your requests. 2Checkout throws an exception if the values are incorrect.  The sessionID expires in 10 minutes.

Order

Required (Object)

 

Object designed to collect all data necessary for an order, including billing, product/subscription plan and payment details.

See code sample for more details. 

Request Example

<?php

require ('PATH_TO_AUTH');

$Order = new stdClass();
$Order->RefNo = NULL;
$Order->Currency = 'USD';
$Order->Country = "RO";
$Order->Language = 'EN';
$Order->CustomerIP = '10.5.22.197';
$Order->ExternalReference = NULL;
$Order->Source = NULL;
$Order->AffiliateId = NULL;
$Order->CustomerReference = NULL;
$Order->Items = array();
$Order->Items[0] = new stdClass();
$Order->Items[0]->Code = 'a01';
$Order->Items[0]->Quantity = 1;
$Order->Items[0]->PriceOptions = NULL;
$Order->Items[0]->SKU = NULL;
$Order->Items[0]->Price = NULL;
$Order->Items[0]->CrossSell = NULL;
$Order->Items[0]->Trial = false;
$Order->Items[0]->AdditionalFields = NULL;
$Order->Items[0]->SubscriptionStartDate = NULL;
$Order->BillingDetails = new stdClass();
$Order->BillingDetails->FirstName = 'John';
$Order->BillingDetails->LastName = 'Doe';
$Order->BillingDetails->CountryCode = "RO";
$Order->BillingDetails->State = 'Bucharest';
$Order->BillingDetails->City = 'Bucharest';
$Order->BillingDetails->Address1 = 'Street Name 555';
$Order->BillingDetails->Address2 = NULL;
$Order->BillingDetails->Zip = '1111111';
$Order->BillingDetails->Email = 'test@2checkout.com';
$Order->BillingDetails->Phone = '00402505555';
$Order->BillingDetails->Company = 'blank';
$Order->DeliveryDetails = new stdClass();
$Order->DeliveryDetails->FirstName = 'John';
$Order->DeliveryDetails->LastName = 'Doe';
$Order->DeliveryDetails->CountryCode = 'NZ';
$Order->DeliveryDetails->State = 'Bucharest';
$Order->DeliveryDetails->City = 'Bucharest';
$Order->DeliveryDetails->Address1 = 'Street Name 555';
$Order->DeliveryDetails->Address2 = NULL;
$Order->DeliveryDetails->Zip = '1111111';
$Order->DeliveryDetails->Email = 'test@2checkout.com';
$Order->DeliveryDetails->Phone = '00402505555';
$Order->DeliveryDetails->Company = NULL;
$Order->PaymentDetails = new stdClass ();

$Order->PaymentDetails->Type = 'WEBMONEY';
$Order->PaymentDetails->Currency = 'USD';
$Order->PaymentDetails->HadPayPalToken = false;
$Order->PaymentDetails->CustomerIP = '10.5.22.197';

$Order->PaymentDetails->PaymentMethod = new stdClass ();
$Order->Promotions = NULL;
$Order->AdditionalFields = NULL;
$Order->LocalTime = NULL;
$Order->GiftDetails = NULL;

try {
   $newOrder = $client->placeOrder($sessionID, $Order);
   var_dump($newOrder);
}
catch (SoapFault $e) {
    echo "newOrder: " . $e->getMessage();
    exit;
}
?>

Response Example

Parameter Type/Description

Order information

Object

  Object containing order information.
  • Was this article helpful?