We are experiencing consistent transaction initiation failures when calling the Paynow InitiateTransaction endpoint. The request fails at the network layer with a connection reset by peer (OS error 104) , before any Paynow response payload is returned.
Did you try to test the payment gate way of paynow locally on your pc. If you did and the payment went through then the paywall or firewall is rejecting outbound requests from the supabase server. If you fail at all options try routing with a vps with static ip address like digital ocean. It will be supabase edge functions - vps - paynow
Regarding issue raised by @Cyberwave , i’m also facing, I have performed the local test as suggested:
Local PC Test: Successful. The payment initiation works perfectly from my local Zimbabwean IP.
Production (Supabase) Test: Fails consistently with Connection reset by peer (os error 104) .
Technical Confirmation from Supabase:I have verified with Supabase technical documentation that Supabase Edge Functions do not have an outbound firewall. They are open by default on port 443. The “Connection Reset” error indicates that the Paynow server is terminating the TCP handshake when it detects a request from a foreign cloud IP range (Supabase uses dynamic global IPs).
Error Log: Type Error: error sending request… client error (Connect): Connection reset by peer (os error 104)`
Request: Since Supabase uses a dynamic IP range, I cannot provide a single static IP for whitelisting. Could you please whitelist to allow API calls originating from international cloud data centers?
@Breezy did you try routing with a vps, if you haven’t try vps routing. Proxy all Paynow API calls through your Contabo VPS rather than calling Paynow directly from Supabase Edge Functions. Your edge function hits your VPS endpoint, your VPS forwards to Paynow, returns the response. Since your VPS has a static IP, you can also formally request Paynow whitelist it via their integration support.
The flow would be:
Supabase Edge Function → VPS (static IP) → Paynow. The vps is the one that provides a static ip not Supabase. Ud expose a small internal proxy endpoint on your VPS — something like /proxy/paynow/initiate — that accepts your signed request, strips your internal auth, and forwards to paynow.co.zw/interface/InitiateTransaction. The edge function never talks to Paynow directly. My thinking, try and report back how would that go. You can try a contabo server its cheaper, you can ssh into it using root cmds or install portainer on the vps for a cleaner deployment via a user friendly ui.
So because of paynow limitations we have to pay for extra services to get paynow working. I’m about to go through the same setup. And this just causes problem. I’m going to use paynow for pan African African payments. By having an additional vps or whatever we just creating extra places where we have to maintain security.
Also on another note, why has the UI and UX for paynow not been updated in years? I remember 8 years ago seeing the same interface? Are you running on some old windows server env where the UI is limited?
Can we contribute as a community to help with the UI/UX?
Hie bryan i do not work at paynow but im just a fellow developer helping people on what i went through and what i found helpful in my journey with paynow. I think they have to fix their outbound and inbound firewall to accept foreign ip addresses. By foreign i mean dynamic ip addresses from outside of Zimbabwe. Thier webside needs a revamp for sure. For now yes we have to stick to a vps solution when we host outside of ZIMBABWE
Paynow API Access – Supabase IP Restrictions & Recommended Workaround
Please note that some Supabase IP addresses used by Paynow integrations have been blocked due to abuse by other merchants.
Because platforms like Supabase and Firebase use shared IP infrastructure, certain merchants were making excessive or improper requests (e.g., continuously polling transaction status), which led to those shared IPs being blocked.
As a result, Paynow is unable to selectively unblock individual users on those shared IPs.
Recommended Workaround
To avoid this issue, you can use one of the following approaches:
Use a dedicated static IP address, or
Proxy all Paynow API calls through your own VPS (e.g., Contabo or any hosting provider)
Suggested Flow
Supabase Edge Function → VPS (Static IP) → Paynow API
Your Supabase Edge Function should call your VPS endpoint
Your VPS then forwards the request to Paynow
The response is returned back through the same path
The key point is that the VPS provides a static, dedicated IP, unlike Supabase.
Important Clarification
Only IPs that have shown abusive behavior are blocked
Paynow does not block international IPs by default
The restriction is based on traffic patterns and misuse, not location