2Checkout Module
Send clients to the 2Checkout payment page and let a notification from 2Checkout close the invoice.
Reaching the Screen
Go to Settings → Financial → Payment Gateways, open All Modules and click the 2Checkout card: {admin}/modules/payment?module=TCO
Adding the gateway to the method list clients see is covered in Payment Modules.
What Is on the Screen
One settings form: the 2Checkout credentials, a test switch and the shared gateway settings every module carries.
The client is moved to the 2Checkout payment page with the order lines and the billing address already filled in. The card never touches your site. 2Checkout then reports the result to your callback address, and that report is what closes the invoice.
The module does not keep cards, does not open subscriptions, offers no installments and cannot refund a payment. Refunds are made in your 2Checkout account.
Before You Configure It
- A 2Checkout account with its merchant code.
- The currency you charge in accepted on that account.
- An address your 2Checkout account can reach over HTTPS, because the result arrives there.
Fields
Status, Commission Rate (%), Converting Currency, Accepted Amount Range and the country lists work the same way in every gateway. See Payment Modules. Callback URL, Success URL and Failed URL cannot be edited: copy them with the icon at the end of the field.
Tasks
Take the credentials from 2Checkout
- Sign in to your 2Checkout account and open Integrations → Webhooks & API.
- Copy the secret key from the API section and the secret word from the INS section.
- Copy your merchant code from the same area. It also appears on your account summary.
Enter the credentials
- Open the module card and tick Status. The other fields stay locked until you do, and nothing else is saved while it is off.
- Fill in Merchant Code, Secret Key and Secret Word.
- Tick Test Mode while you try the flow, and untick it before you take real payments.
- Click Save Changes. Clients who pick this method are now taken to the 2Checkout page.
Register the notification address
- Copy the Callback URL from the module card with the icon at the end of the field.
- Open Integrations → Webhooks & API → INS Settings → Add endpoint. Paste the address, select SHA256 and click Save endpoint.
- Edit the INVOICE_STATUS_CHANGED trigger. Under Parameters, replace md5_hash with hash and click Save trigger.
- Run a test payment and check both the provider transaction and WISECP invoice. The module accepts signed approved and deposited notifications.
What the client goes through
- The client picks this method at checkout, on an invoice or when adding funds.
- A short waiting page appears and the client is moved to the 2Checkout payment page.
- The client pays there and comes back to your site.
- The invoice closes when the notification arrives, which may be a moment later than the return.
Refund a payment
- Refund the order in your 2Checkout account. The module cannot send a refund.
- Open the paid invoice: {admin}/invoices/detail?id={invoice}
- Under Summary → Change Status, select Refunded and Add as expense.
- Click Update Status. WISECP records the refund; this step does not send money again.
Things to Watch
A wrong secret key, secret word or unreachable notification address can leave an invoice unpaid. Check the invoice status with a test payment before offering the method to clients.
A client coming back from 2Checkout may land on the failed payment page even after a successful payment. Judge the payment by the invoice status, not by the page the client saw, and expect the occasional support message about it.
There are no kept cards, no subscriptions and no installments here, and refunds happen in your 2Checkout account. Pick another gateway under Card Storage Module when you want automatic renewal payments.
Required Privileges
Settings require Payment Module Settings (MODULES_PAYMENT_SETTINGS). Invoice changes require Billing → Edit (INVOICES_OPERATION).
Related Articles
Merci pour votre retour !
Notre équipe d'assistance est disponible 24h/24 pour tout ce que vous ne trouvez pas ci-dessus.