Return URLs and payment confirmation
How Viva payment is confirmed at WooCommerce: Success and Failure URL, transaction check, cache and firewall. There is no webhook.
The plugin does not use webhook. The order is updated when the customer, after payment, returns from Viva to your site. Therefore the two URLs must be correct.
| URL on Viva | Quotation | What's going on? |
|---|---|---|
| Success URL | https://το-site-σας/wc-api/WC_Gateway_Viva/ | The plugin asks Viva about the transaction. If it's okay, complete the payment, write the transaction ID and send the customer to the page Order received. |
| Failure URL | https://το-site-σας/wc-api/WC_Gateway_Viva/?status=fail | The customer returns to checkout with an error message. Order stays. Waiting for payment. |
The exact URLs, with your domain, are seen above the fields on the plugin configuration page. In Viva's Payment Source the domain enters the Domain name. In Success URL and Failure URL write only what follows after domain.
What to check#
- In Viva's Payment Source Domain name is just that of the site, with or without
www, as the site opens, and Protocol is https. - The route
/wc-api/WC_Gateway_Viva/is excluded from cache (plugin cache, CDN, Cloudflare) and is not blocked by firewall or safety plugin. - If you have changed domain, protocol or moved the site, update URLs to Viva's Payment Source.
If the client doesn't come back#
If the client closes the browser immediately after payment, the order remains Waiting for payment although Viva has charged the card. Find the transaction to Viva with the Viva Order Code from the order notes and manually change the situation to Edited.
Send a request; the plugin and the article are automatically completed.