Cujiware Gateway – Mercado Pago for WooCommerce

Description

Cujiware Gateway connects your WooCommerce store with Mercado Pago and adds three payment methods:

  • Checkout Pro: the customer is redirected to Mercado Pago to pay with cards, cash, bank transfer or account balance.
  • Card payments (Card Payment Brick): the customer pays with credit or debit card without leaving your store.
  • QR: the customer scans your store QR code and enters the payment voucher number.

Features:

  • Recurring payments for WooCommerce Subscriptions (Mercado Pago preapprovals), including pause, reactivation and cancellation from My Account.
  • Interest-free installments (MSI) and installment limits per product and per category.
  • Surcharges (percentage and/or fixed amount) per payment method.
  • Currency conversion (fixed rate or live rates) when the store currency differs from the Mercado Pago account currency.
  • Marketplace split payments: vendors link their Mercado Pago account (Dokan, WCFM, WC Vendors, Tutor LMS) and the store keeps a commission.
  • Refunds from WooCommerce, payment status synchronization and order notes.
  • Available for every Mercado Pago country: Argentina, Brazil, Chile, Colombia, Mexico, Peru, Uruguay and Venezuela.

A paid Cujiware license is required. This plugin is the WordPress connector of the Cujiware service, a paid hosted service that provides:

  • the payment processing logic (Checkout Pro preferences, card payments, QR validation, refunds and installment calculations);
  • the reception and processing of Mercado Pago webhooks/notifications and the signed callbacks to your store;
  • the marketplace split payments and the vendor account linking (OAuth);
  • the synchronization of subscriptions (preapprovals) with WooCommerce Subscriptions;
  • the license validation.

Without an active license the payment methods are not available. Plans and purchase: https://cujiware.com/suscripcion

The data exchanged with the Cujiware service is described in the “External services” section below.

External services

This plugin relies on the following third-party services. No data is sent to them until the store administrator saves a Cujiware license in WooCommerce > Settings > Integration > Mercado Pago Tools Pro.

Cujiware service

The Cujiware service validates the license and performs all the communication with Mercado Pago on behalf of the store (it creates checkouts, card payments, subscriptions and refunds, receives Mercado Pago notifications and renders the payment forms and settings pages).

What is sent and when:

  • When the license is saved or validated: the license key, the site URL, the notification (callback) URL and the plugin version.
  • When the administrator opens the plugin or payment method settings: the store country and currency, the site language, the administrator email address, the site home URL, the plugin URL, the WordPress admin URL, the vendor account linking URL and the URL of the uploaded QR image, to render the settings forms.
  • When the settings are saved: the plugin settings, the store country and currency, and the Mercado Pago credentials of the store (access token, public key and, if marketplace is enabled, client ID and client secret).
  • When a customer views the checkout, the cart or a product page, and when the administrator opens the settings: the cart or product items (name, quantity, price, image URL, installment settings), totals, currency, site language and price format, to render the payment forms.
  • When a customer pays: the order (number, items, totals, shipping, currency, return URLs), the customer billing data (name, email, phone, address, postcode and, when requested, identification type and number), the Mercado Pago device ID and, for subscriptions, the billing period and amounts.
  • When the marketplace feature is enabled: the Mercado Pago access tokens of the vendors that linked their account and their commission settings.
  • Periodically (WP-Cron) and when Mercado Pago sends a notification: payment, order and subscription identifiers to synchronize their status.

Every request is signed with a per-site secret. The service also sends signed payment events to the store at ?wc-api=kmercadopago_callback.

  • Terms of service: https://cujiware.com/terminos
  • Privacy policy: https://cujiware.com/privacidad

Mercado Pago (https://www.mercadopago.com)

Payments are processed by Mercado Pago. In the store front-end the plugin loads the Mercado Pago scripts https://www.mercadopago.com/v2/security.js (device fingerprint for fraud prevention, on every page), https://sdk.mercadopago.com/js/v2 (card form, on the order payment page) and https://secure.mlstatic.com/sdk/javascript/v1/mercadopago.js (installment calculator, on product and checkout pages when a public key is configured). Customers paying with Checkout Pro are redirected to Mercado Pago, and vendors linking their account are redirected to https://auth.mercadopago.com.

  • Terms and conditions: https://www.mercadopago.com.ar/ayuda/terminos-y-politicas_194
  • Privacy policy: https://www.mercadopago.com.ar/privacidad

Installation

  1. Install and activate WooCommerce.
  2. Upload the plugin folder to /wp-content/plugins/ or install it from the Plugins screen, then activate it.
  3. Go to WooCommerce > Settings > Integration > Mercado Pago Tools Pro, enter your Cujiware license and save.
  4. Enter your Mercado Pago credentials (access token and public key) and save.
  5. Enable the payment methods in WooCommerce > Settings > Payments.

FAQ

Do I need a Mercado Pago account?

Yes. You need a Mercado Pago seller account and its production (or test) credentials.

Do I need a license?

Yes. The plugin requires a paid Cujiware license. The Cujiware service validates the license and runs the payment processing logic, the Mercado Pago webhooks and callbacks, the marketplace split payments and the subscriptions synchronization. Without an active license the Mercado Pago payment methods are not shown. You can see the plans and buy a license at https://cujiware.com/suscripcion

What happens if the Cujiware service or Mercado Pago is down?

Your store keeps working. The Mercado Pago payment methods are hidden at checkout until the service is available again, and pending notifications are processed automatically afterwards.

I am upgrading from version 2.x. Do I need to configure anything?

No. The settings, orders, subscriptions and linked vendors are kept, the saved license is activated automatically and the old version is deactivated (its files are not deleted).

Which subscription plugin is supported?

WooCommerce Subscriptions.

Reviews

There are no reviews for this plugin.

Contributors & Developers

“Cujiware Gateway – Mercado Pago for WooCommerce” is open source software. The following people have contributed to this plugin.

Contributors

Changelog

3.0.2

  • New: Spanish (es_AR, es_CL, es_CO, es_ES, es_MX, es_PE, es_UY, es_VE) and Portuguese (pt_BR) translations included in the plugin. They are used only when translate.wordpress.org has no language pack for the site language.

3.0.1

  • Changed: the plugin and the Cujiware service now exchange only their own minimal data format. No Mercado Pago object is sent to or received from the store any more (responses, callbacks, errors and requests).
  • Changed: every request to the service carries the plugin, WooCommerce, WordPress and PHP versions inside the signed body.
  • Removed: the woocommerce_kmercadopago_args filter. Use the new kmercadopago_checkout_overrides filter instead: apply_filters( 'kmercadopago_checkout_overrides', array(), $order, $gateway_id ) returns an array with any of statement_descriptor (string, up to 22 letters, digits, spaces, ., *, -), item_title (string), description (string), binary_mode (bool), metadata (array of scalar values, keys a-z0-9_), and, for Checkout Pro only, excluded_methods (string[]), excluded_types (string[]: credit_card, debit_card, ticket, atm, bank_transfer, prepaid_card, digital_currency, digital_wallet, account_money), max_installments (1-48) and expiration_minutes (5-525600). Values are validated by the service; invalid values are ignored. Order reference, notification URL, amounts and fees can not be changed.
  • Changed: kmercadopago_get_preapproval() and the kmercadopago_pre_update_subscription / kmercadopago_post_update_subscription hooks now receive the subscription as an array with ref, order_id, state (pending, active, paused, cancelled), amount, currency, reason, billing (interval, unit), next_charge_at and started_at (Unix timestamps or null), trial (length, unit, or null), charges (count, last_at) and plan_ref. The third argument of kmercadopago_post_update_subscription is false or an array with updated, http_code, amount and reason.
  • Changed: kmercadopago_get_preapproval_plan() returns ref, active, amount, currency, reason and billing. The third argument of kmercadopago_post_sync_subscription_amount is an array with changed, amount_changed, amount and reason.
  • Changed: the mp_preferences and mp_tokenize order data are no longer written.
  • Fixed: the Mercado Pago order number is saved on approved payments.
  • Changed: the plugin hooks, cron events and schedules, script handles, classes, tables and stored keys now use the kmercadopago prefix. Renamed: actions check_ipn_response -> kmercadopago_check_ipn_response and woocommerce_kmercadopago_metabox -> kmercadopago_metabox; cron events woo_sub_cronjob_function -> kmercadopago_sub_cron, do_kmercadopago_hourly_check -> kmercadopago_hourly_check, do_kmercadopago_refresh_token -> kmercadopago_refresh_token; schedule 5_minutes -> kmercadopago_five_minutes; classes WC_KMercadoPago* -> KMercadoPago*; tables woo_kmercadopago / woo_kmercadopago_sub -> kmercadopago / kmercadopago_sub; product and category meta _max_installments, _marketplace_fee, _fee_installments_msi_* -> _kmercadopago_*. Existing data, scheduled events and webhook URLs are migrated or keep working automatically.
  • Changed: the QR image is stored in wp-content/uploads/cujiware-gateway-mercado-pago/qr.png (the previous image is copied automatically).
  • Changed: translations are delivered by translate.wordpress.org.
  • Changed: admin notices are only shown on the plugin settings screen to users who can manage WooCommerce.

3.0.0

  • New: payment logic moved to the Cujiware service; the plugin code is now open source (GPLv2 or later).
  • New: plugin renamed to “Cujiware Gateway – Mercado Pago for WooCommerce” (slug cujiware-gateway-mercado-pago). Version 2.x is deactivated automatically on upgrade and all its data is kept.
  • New: English source texts with Spanish (es_ES, es_AR, es_MX, es_CO, es_CL, es_PE, es_UY, es_VE) and Brazilian Portuguese translations.
  • New: the Mercado Pago payment methods are hidden automatically while Mercado Pago or the service is unavailable.
  • Security: nonces on all forms and AJAX requests, sanitized input and escaped output, signed service callbacks.
  • Improved: the QR image upload uses the WordPress upload API.