• Resolved rahilwazir

    (@rahilwazir)


    Hi,

    I’m trying to catch the response of a successful order transaction. What happens to be received in the GoodURL parameter, which is fine.

    But I’m curious as to why there’s a webhook response API hook (as we usually see with other gateways like PayPal and Stripe):

    add_action( "woocommerce_api_{$this}", array( $this, 'check_ipn_response' ) );

    But this is never called if I’m not wrong. So could you clarify, if it’s just there for prototype purposes or is there any actual use-case?

    Similarly, the WC_Pelecard_Gateway::form() method does not appear to be called either.

    I would appreciate your reply on this matter as I have a serious integration with Pelecard, so I don’t want to miss any transaction data.

    Thanks

Viewing 4 replies - 1 through 4 (of 4 total)
  • The IPN is sent to ServerSideGoodFeedbackURL and is being handled by the hook you’ve mentioned.

    The form() method should only be utilized for self-hosted payment-forms, which is irrelevant in our case.

    Version 1.4 is scheduled to be released next month, which will be a complete refactoring of the plugin – stay tuned.

    Thread Starter rahilwazir

    (@rahilwazir)

    Thank you for the reply.

    I can see the parameter. So ServerSideGoodFeedbackURL only handles the save card session for WooCommerce, but is the actual IPN response received in GoodURL yes?

    No.

    Currently GoodURL has no functionality – it only redirects the client to the thank-you page.

    The entire logic is being handled by the IPN (ServerSideGoodFeedbackURL), which is being fired before client redirection.

    Thread Starter rahilwazir

    (@rahilwazir)

    I’m not sure if that’s the case for me.

    The GoodURL is what returns me the IPN response. The URL set in ServerSideGoodFeedbackURL is never fired, it is confirmed because the card was never saved to WooCommerce.

    The following is what I have received in GoodURL:

    {
    "ApprovalNo": "",
    "ConfirmationKey": "227658f391316fb0bd8fa5647bd6e921",
    "ParamX": "685",
    "PelecardStatusCode": "000",
    "PelecardTransactionId": "a93c63f3-43b7-4ce3-8099-82aa1e18406a",
    "Token": "8162965969",
    "UserKey": "wc_order_kVFirzLAn7kej",        
    }
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Webhook response’ is closed to new replies.