Jump to content
  • 0

Processing Payment


Question

Posted

Hi,

 

I got question about payment process for the non-merchant gateway

my transaction doesn't get recorded into the system after I call the callback/return url

 

basically my validate/success function is as: (using get method to test)

    public function success(array $get, array $post) {

        $client_id = $this->ifSet($get['cid']);
        $return = array(
            'client_id' => $client_id,
            'amount' => $this->ifSet($get['amount']),
            'currency' => $this->ifSet($get['currency']),
            'invoices' => $this->unserializeInvoices($this->ifSet($get['inv'])),
            'status' => "approved",
            'transaction_id' => $this->ifSet($get['txid']),
            'parent_transaction_id' => $this->ifSet($get['txid'])
        );
        return $return;
    }

and I called the return/callback url with the param:

?currency=IDR&cid=3&txid=1234&amount=1000.000&inv=32=1000.0000

But the invoices doesn't get credited, it still have outstanding payment of 1000

and I don't see any transaction being recorded

 

 

Is there any functions to record the payment transaction that I missed?

 

4 answers to this question

Recommended Posts

  • 0
Posted

The return URL is the URL the client gets returned to when they come back from the non-merchant gateway's website. The callback URL is where the gateway will respond to the payment to notify Blesta that a payment has been received. If the gateway does not support both of these URLs, then use the callback URL to do both.

  • 0
Posted

May I ask about what's the point of the success function from https://docs.blesta.com/display/dev/Non-merchant+Gateway+Methods#Non-merchantGatewayMethods-success%28array$get,array$post%29

from what I see the codes are similar to the validate function

 

unless the documentation a bit outdated, shouldn't it do something else like setting the view (for thank you message, etc...) rather than having the same function?

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...