Request for invoice generation/payment

Request for invoice generation/payment in a single request (any payment method)
  • It is possible to register the payment and submit cardholder data for processing using a single request.
  • To do so the invoice request and payment data should be submitted together.
  • Method: POST , URL: /invoice/process
  • Request parameters (M – mandatory):
Field Usage Description
order_id M Unique order ID/bill number in the merchant system (max 30 symbols)
amount M Payment amount. Decimal point – “.” Two decimal digits available (example: 200.00). (amount value > 0)
currency M Currency (alphabetic code, example EUR, 3 symbols based on ISO 4217)
payment_method M Payment method. Described in the section Available payment methods
due_date
Order/Bill due date. Expiration time until order can be paid.
ISO format (example: 2017-04-07T10:37:52.789Z )
If the field is empty, then shop's configuration value is used
required_connector_name Connector code selected by the merchant. If connector is not registered in gateway system or wrong name then error message will be returned.
Customer information
customer.personal_code Personal identification number (max 25 symbols)
customer.first_name Customer's name. It is designed to identify a customer and prevent fraud (max 50 symbols)
customer.last_name Customer's last name. It is designed to identify a customer and prevent fraud (max 50 symbols)
customer.email Customer's e-mail address. It is designed to identify a customer and prevent fraud (max 50 symbols)
customer.zip ZIP code (max 50 symbols)
customer.city Customer's city. It is designed to identify a customer and prevent fraud (max 50 symbols)
customer.address Address (max 50 symbols)
customer.phone Phone (max 50 symbols)
customer.site_id Customer Id on site of merchant (max 50 symbols)
customer.country Customer's country. It is designed to identify a customer and prevent fraud (2 symbols code, example LV, US, etc)
customer.user_time Local time (max 50 symbols)
customer.user_timezone Local time zone (max 50 symbols)
customer.ip M* Original request IP address (max 30 symbols)
customer.referer Original request referrer (max 2000 symbols)
customer.additional_params M*
Additional parameter array (e.g. browser data etc.) Form: customer.additional_params['key'] = 'key_value'
(key – max 50 symbols, key_value – max 255 symbols)
Fraud monitoring:
1. In case of fraud monitoring enabled for connector the following parameters are mandatory:
customer.additional_params['client_data'] (max 32 symbols)
To get the value for this parameter you need to concatenate the following values and take MD5 hash:
navigator.appCodeName, navigator.appName, navigator.appVersion, navigator.cookieEnabled,
navigator.platform, navigator.userAgent, screen.height, screen.width, screen.colorDepth,
timezoneOffset, navigator.language,navigator.plugins, navigator.mimeTypes
customer.additional_params['session_id'] (max 32 symbols)
MD5 hash from unique session ID associated with current invoice processing
2. Parameter customer.additional_params['server_fingerprint'] (max 32 symbols) is optional
MD5 hash generated from all values of requestHeader except host, referer, content-length, cookie, Http-X-ForWarded-For, cookie2
example:
customer.additional_params['screen_resolution'] = '800x600'
customer.additional_params['cookie_info_id'] = 'info'
customer.additional_params['locale'] = 'en_US' or customer.additional_params['locale'] = 'en'. Both formats are valid.
(It is used for payment form language definition. Validation is based on ISO standard definition http://www.oracle.com/us/technologies/java/locale-140624.html )
customer.additional_data Additional data in text format (max 1024 symbols)
List of products relevant to the payment
(Index of first product must be 0. Products are in form of array with name "products" in case of JSON)
product[i].name Product name (max 100 symbols)
product[i].amount Amount (Decimal point – “.” Two decimal digits available (example: 200.00))
product[i].discount Discount of product (amount)
product[i].discount_percent Discount percentage (from 0.00 to 100.00, two fraction digits)
product[i].unit Unit value (max 50 symbols)
product[i].vat VAT amount (Decimal point – “.” Two decimal digits available (example: 200.00))
product[i].vat_percent VAT percentage (positive (or zero) decimal value, fraction - 2 digits)
Input parameters for dynamic descriptor
merchant_name_a Allowed prefix for dynamic merchant name generation (max 50 symbols). Allowed length should be agreed with client administrator.
merchant_name_b Allowed suffix for dynamic merchant name generation (max 50 symbols). Allowed length should be agreed with client administrator.
Card data parameters
card_info.mpi_callback_url
Return URL after 3D-Secure (MPI) authentication to merchant website.
Invoice_ref will be added automatically to the url.
card_info.cardholder M
Cardholder name. Supported conditions:

• Apostrophe (') for names like "Gareth O'Hare"
• Minus for double names like "Alexandru-Cristian"
• Dot (.) for honorific prefixes like "MR.", "MRS.", "MISS.", "MS.", "DR.", "THE."
• Dot (.) for initials like "Jimmy L. Morgan", "J.P. Teron"
• Length of name max 30 symbols, min 3 symbols

+Latvian and Russian symbols

Pattern:
"${cardholder.name.regex:^[ A-Za-z" + // ASCII
"'-." + // Special
"\\u0410-\\u044F\\u0451\\u0401" + // Russian
"\\u0100\\u0101\\u0112\\u0113\\u012A\\u012B\\u014C\\u014D\\u016A\\u016B\\u010C\\u010D\\" +
"u0122\\u0123\\u0136\\u0137\\u013B\\u013C\\u0145\\u0146\\u0156\\u0157\\u0160\\u0161\\u017D\\u017E" + // Latvian
"]{3,30}$}"
card_info.pan M card number
card_info.cvc M security code (3 digits for VISA and MC, 4 for Amex)
card_info.expiry M Expiration date, format MMYY
  • Fields for signature calculation:
    <order_id><amount><currency><payment_method><X-Shop-Name><X-Nonce><ShopPassword>
  • M*- Mandatory for fraud monitoring
Request for invoice generation/payment in a single request (any payment method) example
  {
  "order_id": "order-26",
  "amount": 9.99,
  "currency": "USD",
  "payment_method": "FD_SMS",
  "customer": {},
  "products": [],
  "merchant_name_a": "",
  "merchant_name_b": "",
  "card_info": {
    "cardholder": "John Smith",
    "pan": "4111111111111111",
    "cvc": "123",
    "expiry": "1220"
    }
  }

  If MPI verification is required, then additional field should be provided
  "card_info": {
        ...,
      "mpi_callback_url": "https://merchantsite.example.com/mpi_callback"
 }